version build

This commit is contained in:
Krzysztof
2025-08-03 12:17:15 +02:00
parent 27e89b297a
commit 17d11decaa
10 changed files with 60 additions and 31 deletions

View File

@@ -9,22 +9,22 @@ jobs:
contents: write
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v4
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: '1.24'
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: "1.24"
- name: Build
run: CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o uptimemonitor ./cmd/uptimemonitor
- name: Build
run: CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o uptimemonitor -ldflags "-X version.Version=$(git describe --tags)" ./cmd/uptimemonitor
- name: Release
uses: softprops/action-gh-release@v2
if: github.ref_type == 'tag'
with:
files:
uptimemonitor
- name: Release
uses: softprops/action-gh-release@v2
if: github.ref_type == 'tag'
with:
files:
uptimemonitor
- name: Test
run: go run gotest.tools/gotestsum@latest --format testdox -- ./test
- name: Test
run: go run gotest.tools/gotestsum@latest --format testdox -- ./test