ajoberstar / reckon

Infer a project's version from your Git repository.
Apache License 2.0
185 stars 28 forks source link

Support for gitflow branch names in Reckon #117

Closed felixgonschorek closed 5 years ago

felixgonschorek commented 5 years ago

Hi, I am trying to get Reckon to create versions for gitflow feature/hotfix etc. branches.

E.g.: The branch "feature/newfeature" is checked out and the last release tag is "1.0.0". I want Reckon to set the version to "1.0.0-newfeature-SNAPSHOT".

Any ideas how to achieve this? Or does this approach not compliant with the strict SemVer approach?

Support for this was mentioned in issue #11 Thank you!

ajoberstar commented 5 years ago

The use of newfeature as the stage wouldn't be compliant, just given the alphabetical sorting SemVer uses for that part of the version number. In practice you may not care if newfeature is considered newer than newestfeature, but it wouldn't be strictly compliant.

The main aspect of GitFlow that I was wanting to address in #11 was just the idea that you have certain parallel development going on, and how does Reckon figure out what version each branch is targeting. There's some logic for this now, but it isn't quite up to handling all scenarios yet. It may involve using branch naming schemes to hint at the correct version and/or scope of change.

Let me know if you have other thoughts on this.

felixgonschorek commented 5 years ago

thank you for your feedback, i see that this is a complex scenario to get right. i think i will approach this from a different angle.