get-next-version icon indicating copy to clipboard operation
get-next-version copied to clipboard

`get-next-version` can't handle a commit tagged with multiple version granularity tags

Open duckpuppy opened this issue 1 year ago • 1 comments

What happened incorrectly?

A git commit tagged with, for example, v4, v4.5, and v4.5.14 results in get-next-version complaining that the commit is tagged with multiple semver versions. This tagging format is common in some workflows to always point to the most recent v4 release or v4.5 minor release sequence in addition to the specific release commit.

What should have happened instead?

get-next-version should use only the actual semver formatted tag (the one with all version elements) to calculate the next version.

What steps are needed to reproduce the bug?

  • Tag a commit with tags in the format v<major>, v<major>.<minor> and v<major>.<minor>.<patch>
  • run get-next-commit and see the error.

duckpuppy avatar Aug 14 '24 14:08 duckpuppy

Thanks for bringing up this issue.

Since we do not use these shortened version numbers in our processes, we are not planning to implement this.

However, if you come up with a PR, we would be happy to merge it.

goloroden avatar Aug 15 '24 05:08 goloroden