Skip to content

Commit ca194cc

Browse files
committed
chore: add release script that uses --tag for npm publish for 4.x releases
Fix #6063
1 parent b447d65 commit ca194cc

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

package.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,8 @@
7777
"install-browser": "npm install `node format_deps.js`",
7878
"lint": "eslint . --quiet",
7979
"nsp": "nsp check",
80+
"release": "git push origin master --tags && npm publish",
81+
"release-legacy": "git push origin 4.x --tags && npm publish --tag 4.x",
8082
"test": "mocha test/*.test.js test/**/*.test.js",
8183
"test-cov": "istanbul cover --report text --report html _mocha test/*.test.js"
8284
},

release-items.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
3. update History.md using `git changelog` or similar. Add #<TICKET_NUMBER> as well as a link to the github user who fixed it if applicable.
66
4. git commit -a -m 'release x.x.x'
77
5. git tag x.x.x
8-
6. git push origin BRANCH --tags && npm publish
8+
6. `npm run release`, or `npm run release-legacy` for 4.x
99
7. update mongoosejs.com (see "updating the website" below)
1010
8. tweet changelog link from [@mongoosejs](https://twitter.com/mongoosejs)
1111
9. Announce on mongoosejsteam slack channel

0 commit comments

Comments
 (0)