Skip to content

Commit

Permalink
fix: docs about default ldflag template (#1265)
Browse files Browse the repository at this point in the history
The docs state that the default ldflags includes the ShortCommit but in
reality the code uses the longer Commit value instead. This behavior has
existed since the defaults were introduced ~3 years ago in commit
4af2cb0.

Fixes #1264
  • Loading branch information
leighmcculloch authored and caarlos0 committed Nov 28, 2019
1 parent 36126ec commit 6a759c1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion www/content/build.md
Expand Up @@ -49,7 +49,7 @@ builds:
- ./dontoptimizeme=-N

# Custom ldflags templates.
# Default is `-s -w -X main.version={{.Version}} -X main.commit={{.ShortCommit}} -X main.date={{.Date}} -X main.builtBy=goreleaser`.
# Default is `-s -w -X main.version={{.Version}} -X main.commit={{.Commit}} -X main.date={{.Date}} -X main.builtBy=goreleaser`.
ldflags:
- -s -w -X main.build={{.Version}}
- ./usemsan=-msan
Expand Down

0 comments on commit 6a759c1

Please sign in to comment.