Skip to content

Commit

Permalink
fix a bug in npm script postversion caused by double digit semvar
Browse files Browse the repository at this point in the history
when semvar goes from say 1.2.9 to 1.2.10, `git tag | tail -1` doesn't get 1.2.10 because it's sorted together with 1.2.1
  • Loading branch information
ZYinMD committed Jan 19, 2019
1 parent d2f33ea commit 3b0493f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
"scripts": {
"visualize": "node ./scripts/visualize.js",
"postvisualize": "printf 'For faster speed, you might want to run `node ./scripts/visualize.js` directly'",
"postversion": "auto-changelog -b 99 && git commit -a --amend --no-edit && git tag -f $(git tag | tail -1) HEAD"
"postversion": "auto-changelog -b 99 && git commit -a --amend --no-edit && git tag -f $(git describe --tags) HEAD"
},
"devDependencies": {
"auto-changelog": "^1.10.2",
Expand Down

0 comments on commit 3b0493f

Please sign in to comment.