Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/add preid param for semver #122

Closed
AntJanus opened this issue Oct 6, 2016 · 8 comments
Closed

Feature/add preid param for semver #122

AntJanus opened this issue Oct 6, 2016 · 8 comments

Comments

@AntJanus
Copy link

AntJanus commented Oct 6, 2016

Issue to discuss #83

The idea is to allow adding identifiers to certain tags upon release such as beta, dev, rc, etc.

The proposed command would be:

standard-version -p --tag="<identifier>"

So that running standard-version -p --tag="special-release" would result in a tag something like 2.0.0-special-release.0. Using the prelease command -p repeatedly on the same semver version results in an increment to the last number in the series. So running that previous command again would result in 2.0.0-special-release.1

@AntJanus
Copy link
Author

AntJanus commented Oct 6, 2016

One issue I opened a few days ago that got me into this was just having the ability to name major releases. I'm a huge fan of pop-culture naming major releases because it makes it easier to refer back to a certain version when discussing it internally or even with the community. For example using 2.0.0-coruscant (actual version from a work project)

@Tapppi
Copy link
Member

Tapppi commented Oct 7, 2016

So to support tags AND pre-releases separately, we would indeed need both the --prerelease and --tag (kind of a confusing name IMHO, with git tag and all?) to enable releasing something like 2.0.0-coruscant along with the pre-releases? Sounds good to me.

@nexdrew
Copy link
Member

nexdrew commented Oct 7, 2016

I agree that --tag is confusing and would prefer another name, though a better alternative is escaping me at the moment.

When it comes to "named" releases (not prerelease), does the name have to part of the actual version? Will that not break semver and subsequent runs of standard-version? I think it would be better to leave tags/names out of the actual version string and instead be referenced elsewhere.

@Tapppi
Copy link
Member

Tapppi commented Oct 7, 2016

@nexdrew good point about named releases and semver. I mean you could just make another tag to name the version, whatever you want that to be then.. Thoughts @AntJanus?

If named releases are a non-problem, then as @stevemao suggested in the previous PR we can just merge the --tag option into the --pre-release option. If you do not supply a tag (i.e. you run standard-version -p) you get the default, but you can specify the identifier with the same flag that turns it into a pre-release, e.g. standard-version -p="very-special-pre-release". /CC @bcoe

@e-cloud
Copy link
Contributor

e-cloud commented Oct 14, 2016

agree with @nexdrew , named major version is not supported by semver lib yet.

@bcoe
Copy link
Member

bcoe commented Nov 13, 2016

Hello all, sorry for being AWOL; npm, IstanbulJS, and yargs have all been quite busy lately and I've been spread a bit too thin.

Regarding incrementing logic:

I like this approach a lot as a start @AntJanus:

So running that previous command again would result in 2.0.0-special-release.1

Regarding named major releases:

Regarding named major releases, I'm inclined to keep that discussion out of this thread; not that it's not a feature we should consider, but mainly it feels like a different set of concerns.

Changelogs

One standing question I have, is what does the changelog look like for pre-release versions, my preference would be having an Upcoming section in the CHANGELOG.md; that would then become the next release, once a non-pre-release version is released. How do folks feel about this? I wonder how hard this would be to pull off.

@Tapppi
Copy link
Member

Tapppi commented Dec 1, 2016

Has this been superseeded by #146?

@bcoe
Copy link
Member

bcoe commented Dec 18, 2016

@Tapppi @AntJanus I agree, I've been using the new --prerelease and --release-as functionality, and I believe it does a good job of hitting an 80/20 with regards to cutting special releases.

Let's move any further discussion about pre-release improvements to #146.

@bcoe bcoe closed this as completed Dec 18, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

5 participants