Skip to content

Commit

Permalink
Use git describe
Browse files Browse the repository at this point in the history
  • Loading branch information
Dennis Staal committed Feb 6, 2024
1 parent 9ac1929 commit 227f9a5
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions .github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,11 @@ jobs:
with:
go-version: 1.18

- name: Checkout code
uses: actions/checkout@v4

- name: Build
run: |
echo "Build James" git describe --tags
go build -ldflags "-X main.Build=${GITHUB_REF#refs/tags/v}" -v ./...
LATEST_TAG=$(git describe --tags)
echo Build James $LATEST_TAG
go build -ldflags "-X main.Build=$(LATEST_TAG)" -v ./...
- name: Test
run: go test -v ./...

0 comments on commit 227f9a5

Please sign in to comment.