standard-version icon indicating copy to clipboard operation
standard-version copied to clipboard

Why new version changelog still include previous version release changlog?

Open lovetingyuan opened this issue 3 years ago • 3 comments
trafficstars

npx standard-version -p beta --preMajor -r patch --skip.tag --header="### Wyxc" --path ./

Wyxc

0.0.1-beta.7 (2022-03-10)

Features

  • huhu: sfsd 9c5c0cd

Bug Fixes

  • sdfs: dsjfkds ef048c3

0.0.1-beta.6 (2022-03-10)

Features

  • huhu: sfsd 9c5c0cd

0.0.1-beta.5 (2022-03-10)

Features

  • huhu: sfsd 9c5c0cd

lovetingyuan avatar Mar 10 '22 10:03 lovetingyuan

It seems that an answer was given in issue 628.

thetaPC avatar Mar 15 '22 20:03 thetaPC

It seems that an answer was given in issue 628.

Yes, this was exactly my case. It seems like standard-version use git tags to distinguish changes between versions for generating a changelog.

In my case, we used just the version number (without the "v" prefix which is default for standard-version) for a git tag. So the solution was to set an empty string for the tag via option --tag-prefix "" when running standard-version.

But I am not sure about standard-version works correctly if you are not using git tags at all :\

JJetmar avatar Mar 16 '22 13:03 JJetmar

For reference to other people coming into this issue, we're using a gitflow setup and manual tags being set on master instead of develop, our tags fit under the format 1.0.0, 1.0.1, 1.1.0,...

Just spent some time looking at the multiple different issues regarding this (#277, #509 and #628 mainly), and --tag-prefix "" was the fix for us as well, looks like it is indeed expecting a format v1.0.0, v1.0.1, v1.1.0,... by default

AnthonyLenglet avatar Sep 19 '22 14:09 AnthonyLenglet