fix ldflags

This commit is contained in:
Krzysztof
2025-08-03 12:24:29 +02:00
parent 17d11decaa
commit 68308121b8
3 changed files with 3 additions and 3 deletions

View File

@@ -17,7 +17,7 @@ jobs:
go-version: "1.24"
- name: Build
run: CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o uptimemonitor -ldflags "-X version.Version=$(git describe --tags)" ./cmd/uptimemonitor
run: CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o uptimemonitor -ldflags "-X uptimemonitor/pkg/version.Version=$(git describe --tags)" ./cmd/uptimemonitor
- name: Release
uses: softprops/action-gh-release@v2

View File

@@ -10,7 +10,7 @@ watch:
.PHONY: build
build:
go build -o ./tmp/main ./cmd/uptimemonitor
go build -o ./tmp/main -ldflags "-X uptimemonitor/pkg/version.Version=dev" ./cmd/uptimemonitor
.PHONY: test
test:

View File

@@ -1,3 +1,3 @@
package version
var Version string = "dev"
var Version string = ""