1
0
mirror of https://github.com/goreleaser/goreleaser.git synced 2025-01-10 03:47:03 +02:00

feat: Change default release name to match tag

I updated the default release name to match
the git tag, per the request in the PR.

Signed-off-by: Matt Stratton <matt.stratton@gmail.com>
This commit is contained in:
Matt Stratton 2017-10-07 15:32:04 -05:00
parent ffebc52458
commit ee67918187
No known key found for this signature in database
GPG Key ID: EF2B156510452D81
2 changed files with 8 additions and 3 deletions

View File

@ -24,8 +24,13 @@ release:
# Default is false.
prerelease: true
# Optional template to name the release
# Default is the version number
# You can change the name of the GitHub release.
# This is parsed with the Go template engine and the following variables
# are available:
# - ProjectName
# - Tag
# - Version (Git tag without `v` prefix)
# Default is ``
name_template: "{{.ProjectName}}-v{{.Version}}"
```

View File

@ -15,7 +15,7 @@ import (
const NameTemplate = "{{ .Binary }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}{{ if .Arm }}v{{ .Arm }}{{ end }}"
// ReleaseNameTemplate is the default name for the release.
const ReleaseNameTemplate = "{{ .Version }}"
const ReleaseNameTemplate = "{{.Tag}}"
// SnapshotNameTemplate represents the default format for snapshot release names.
const SnapshotNameTemplate = "SNAPSHOT-{{ .Commit }}"