2024-12-21 13:04:33 +01:00
|
|
|
on: [push]
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
test-on-windows:
|
|
|
|
runs-on: win-10
|
|
|
|
steps:
|
|
|
|
- name: Checkout Code
|
|
|
|
uses: actions/checkout@v3
|
2024-12-21 13:07:19 +01:00
|
|
|
|
|
|
|
- name: Verify Go Installation
|
2024-12-21 14:08:50 +01:00
|
|
|
shell: bash
|
2024-12-21 13:07:19 +01:00
|
|
|
run: |
|
2024-12-21 14:08:50 +01:00
|
|
|
if ! go version; then
|
|
|
|
echo "Go is not installed!"
|
|
|
|
exit 1
|
|
|
|
fi
|
2024-12-21 13:04:33 +01:00
|
|
|
|
|
|
|
- name: Build Go Application
|
2024-12-21 14:08:50 +01:00
|
|
|
shell: bash
|
2024-12-21 13:04:33 +01:00
|
|
|
run: |
|
|
|
|
go build -o spitfire-installer.exe
|
|
|
|
echo "Application built successfully."
|
|
|
|
|
|
|
|
- name: Run Go Application
|
2024-12-21 14:08:50 +01:00
|
|
|
shell: bash
|
2024-12-21 13:04:33 +01:00
|
|
|
run: |
|
|
|
|
./spitfire-installer.exe || echo "Application failed to run."
|
|
|
|
|
|
|
|
test-on-alpine:
|
|
|
|
runs-on: alpine-1.20
|
|
|
|
steps:
|
|
|
|
- name: Checkout Code
|
|
|
|
uses: actions/checkout@v3
|
|
|
|
|
2024-12-21 13:07:19 +01:00
|
|
|
- name: Verify Go Installation
|
2024-12-21 13:04:33 +01:00
|
|
|
run: |
|
2024-12-21 13:07:19 +01:00
|
|
|
go version || (echo "Go is not installed!" && exit 1)
|
2024-12-21 13:04:33 +01:00
|
|
|
|
|
|
|
- name: Build Go Application
|
|
|
|
run: |
|
|
|
|
go build -o spitfire-installer
|
|
|
|
echo "Application built successfully."
|
|
|
|
|
|
|
|
- name: Run Go Application
|
|
|
|
run: |
|
|
|
|
./spitfire-installer || echo "Application failed to run."
|
2024-12-21 14:08:50 +01:00
|
|
|
|