"feat:" commits causing PATCH instead of MINOR
See original GitHub issueWe are using version 7.0.0
.
Expected behavior:
feat:
commit messages should result in a MINOR bump.
Actual behavior:
feat:
commit messages result in a PATCH bump.
Details:
We have our pipeline set up to release on every commit to master, notice how both fix
and feat
result in patches:
Here is the output from standard-version
on a feat:
release:
$ npx standard-version --infile docs/CHANGELOG.md
✔ bumping version in package.json from 0.14.6 to 0.14.7
✔ outputting changes to docs/CHANGELOG.md
✔ committing package.json and docs/CHANGELOG.md
✔ tagging release v0.14.7
ℹ Run `git push --follow-tags origin master && npm publish` to publish
Here is the resulting commit:
Issue Analytics
- State:
- Created 4 years ago
- Reactions:1
- Comments:5 (2 by maintainers)
Top Results From Across the Web
conventional commit messaging - Conventional Commits
fix type commits should be translated to PATCH releases. feat type commits should be translated to MINOR releases. Commits with BREAKING CHANGE in...
Read more >Generating changelog automatically with Standard Version
Creating a “feat” commit means introducing a new feature. Therefore, it increases the minor version. A commit marked as a breaking change ...
Read more >Understanding Semantic Commit Messages Using Git and ...
Let's explain the Semantic Commits term and demonstrate practical examples of commit messages, inspired by the Conventional Commit ...
Read more >Version Incrementing - GitVersion
Commit messages Adding +semver: breaking or +semver: major will cause the major version to be increased, +semver: feature or +semver: minor will bump...
Read more >How are you writing a commit message? - DEV Community
fix : a commit of the (bug)fix type is equal to PATCH in the SemVer. feat : a commit of type feature is...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hey @jbottigliero , thanks for the details!
IMO, the behavior of
standard-version
should not be different for pre-1.0.0 versions. Let me explain why…We run
standard-version
automatically in a CI script, and we really need a way for it to do both MINORs and PATCHes based on commit messages, even in < 1.0.0. We obviously can’t add the--release-as=minor
flag to the CI script, because then every release would be MINOR, which is just as bad as every release being PATCH.So it seems like our only options for pre-1.0.0, is to have every release be a PATCH, or every release be a MINOR, which is not great.
If the functionality for pre-1.0.0 were exactly the same as for post-1.0.0, then both automated and non-automated workflows would be supported completely.
Everyone could do a
BREAKING CHANGE:
for major, afeat:
for minor, and afix:
for patch. And the world would live in perfect harmony, supporting both automated and non-automated workflows, for both pre-1.0.0 and post-1.0.0.Thoughts?
https://github.com/conventional-changelog/conventional-changelog/pull/452#issuecomment-512641237 explains the reasoning for the behavior. The intent is to work well with npm by allowing caret semver ranges to install all non-breaking updates.