Skip to content

Commit

Permalink
set current version, not next when using git tags
Browse files Browse the repository at this point in the history
  • Loading branch information
plorenz committed Jun 11, 2024
1 parent 8fead75 commit 46f5c54
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cmd/common.go
Original file line number Diff line number Diff line change
Expand Up @@ -180,13 +180,13 @@ func (cmd *BaseCommand) EvalCurrentAndNextVersion() {
}

if cmd.useCurrentTag {
tag := cmd.runCommandWithOutput("get current git tag", "git", "describe")
tag := cmd.runCommandWithOutput("get current git tag", "git", "describe", "--tags")
v, err := version.NewVersion(tag[0])
if err != nil {
panic(fmt.Errorf("unable to parse tag %s", tag[0]))
}

cmd.NextVersion = v
cmd.CurrentVersion = v
}

if !cmd.quiet {
Expand Down

0 comments on commit 46f5c54

Please sign in to comment.