You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I run release-it I get an incorrectly calculated version bump - experimenting with git history shows that the new version is calculated by counting changes across the entire history of commits, and all the tags of previously released versions are being ignored.
From what I can tell there are two related problems occurring. The first is that when I try to set tagPrefix manually in the above json it is ignored, apparently because I have set git.tagName and getInitialOptionsonly refers to this setting in calculating tagPrefix, ignoring and overriding any value that comes from .release-it.json. This behaviour contradicts the docs which state that "Options are passed verbatim to conventional-recommended-bump and conventional-changelog-core."
Second, I suspect that ${npm.name} is not being interpolated anywhere when evaluating the tagPrefix that getInitialOptions is calculating per the above. I say this because 1) when I inspect options at runtime I see the uninterpolated value, and this is then passed into conventional-recommended-bump which from its docs I don't think has any concept of interpolating variables in this way; and 2) when I comment out lines 15-16 in getInitialOptions and then set tagPrefix in .release-it.json to the relevant hard coded value, dry runs show the version bumps are now calculated correctly.
Thanks for your help.
The text was updated successfully, but these errors were encountered:
What I meant here was (only) the plugin options. The plugin options should be sent to the libs you mention. That might also shed light on the ${npm.name} issue, right?
Feel free to open a PR with a fix here or in release-it core, happy to look into it.
I have the following
.release-it.json
:When I run
release-it
I get an incorrectly calculated version bump - experimenting with git history shows that the new version is calculated by counting changes across the entire history of commits, and all the tags of previously released versions are being ignored.From what I can tell there are two related problems occurring. The first is that when I try to set
tagPrefix
manually in the above json it is ignored, apparently because I have setgit.tagName
andgetInitialOptions
only refers to this setting in calculatingtagPrefix
, ignoring and overriding any value that comes from.release-it.json
. This behaviour contradicts the docs which state that "Options are passed verbatim to conventional-recommended-bump and conventional-changelog-core."Second, I suspect that
${npm.name}
is not being interpolated anywhere when evaluating thetagPrefix
thatgetInitialOptions
is calculating per the above. I say this because 1) when I inspect options at runtime I see the uninterpolated value, and this is then passed intoconventional-recommended-bump
which from its docs I don't think has any concept of interpolating variables in this way; and 2) when I comment out lines 15-16 ingetInitialOptions
and then settagPrefix
in.release-it.json
to the relevant hard coded value, dry runs show the version bumps are now calculated correctly.Thanks for your help.
The text was updated successfully, but these errors were encountered: