Skip to content

Commit b74269d

Browse files
committed
tweak release script for manual prerelease
1 parent 57539cc commit b74269d

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
],
1111
"scripts": {
1212
"start": "echo 'Make sure to `cd website && npm install`' && cd website && npm run dev",
13+
"release": "node ./scripts/release.js",
1314
"build-lib": "babel ./modules -d . --ignore '__tests__'",
1415
"build-umd": "webpack modules/index.js umd/react-router.js",
1516
"build-min": "webpack -p modules/index.js umd/react-router.min.js",

scripts/release.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ if (process.cwd() !== resolvePath(__dirname, '..')) {
1919
// is a "pre-release" if nextVersion is premajor, preminor,
2020
// prepatch, or prerelease
2121
const nextVersion = prompt(`Next version (current version is ${getPackageVersion()})? `)
22-
const isPrerelease = nextVersion.substring(0, 3) === 'pre'
22+
const isPrerelease = nextVersion.substring(0, 3) === 'pre' || nextVersion.indexOf('-') !== -1
2323

2424
// 1) Make sure the tests pass
2525
exec('npm test -- --single-run')

0 commit comments

Comments
 (0)