diff --git a/.gitea/workflows/deploy.yml b/.gitea/workflows/deploy.yml index d9cde7b..ffa5ec4 100644 --- a/.gitea/workflows/deploy.yml +++ b/.gitea/workflows/deploy.yml @@ -30,6 +30,8 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 + with: + fetch-depth: 0 - uses: actions/setup-go@v5 with: go-version-file: cmd/rollcall/go.mod @@ -37,7 +39,7 @@ jobs: - name: Build working-directory: cmd/rollcall - run: CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -trimpath -ldflags="-s -w" -o ../../deploy/rollcall . + run: CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -trimpath -ldflags="-s -w -X main.version=$(git describe --tags --always --dirty)" -o ../../deploy/rollcall . - name: SSH setup env: