change system.Version to var so we can set at build

This commit is contained in:
Jakob Schrettenbrunner 2020-07-05 01:26:36 +00:00
parent 7516ef1aa4
commit 31d00333a7
2 changed files with 3 additions and 3 deletions

View File

@ -17,7 +17,7 @@ jobs:
go-version: '^1.14.2' go-version: '^1.14.2'
- name: Build - name: Build
run: GOOS=linux GOARCH=amd64 go build -ldflags="-s -w" -ldflags "-X system.Version=dev-${GIT_COMMIT:0:7}" -o build/wings_linux_amd64 -v wings.go run: GOOS=linux GOARCH=amd64 go build -ldflags="-s -w" -ldflags "-X github.com/pterodactyl/wings/system.Version=dev-${GIT_COMMIT:0:7}" -o build/wings_linux_amd64 -v wings.go
- name: Test - name: Test
run: go test ./... run: go test ./...

View File

@ -1,6 +1,6 @@
package system package system
const ( var (
// The current version of this software. // The current version of this software.
Version = "0.0.1" Version = "0.0.1"
) )