Skip to content

Commit

Permalink
goreleaser: Use .Summary not .Version
Browse files Browse the repository at this point in the history
.Version shows -next for non-tag builds, .Summary shows git describe
like output ({Tag}-$N-{CommitSHA}) so is more useful
  • Loading branch information
mmlb committed Jun 19, 2024
1 parent 452ef8e commit 5156663
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ builds:
ldflags:
- -s -w
- -X github.com/metal-toolbox/version.appName={{.ProjectName}}
- -X github.com/metal-toolbox/version.version={{.Version}}
- -X github.com/metal-toolbox/version.version={{.Summary}}
- -X github.com/metal-toolbox/version.commit={{.Commit}}
- -X github.com/metal-toolbox/version.date={{.Date}}
- -X github.com/metal-toolbox/version.builtBy=goreleaser
Expand All @@ -36,7 +36,7 @@ dockers:
- "--label=org.opencontainers.image.created={{.Date}}"
- "--label=org.opencontainers.image.title={{.ProjectName}}"
- "--label=org.opencontainers.image.revision={{.FullCommit}}"
- "--label=org.opencontainers.image.version={{.Version}}"
- "--label=org.opencontainers.image.version={{.Summary}}"
extra_files:
- dependencies/.gitignore
- use: buildx
Expand Down

0 comments on commit 5156663

Please sign in to comment.