@@ -6,12 +6,14 @@ let _ = require('lodash');
6
6
var argv = require ( 'yargs' )
7
7
. usage ( 'Usage: $0 <packages> [options]' )
8
8
. command ( 'packages' , '[optional] Comma separated list of packages to build.' )
9
+ . alias ( 'c' , 'no-changelog' )
10
+ . describe ( 'c' , 'Do not update CHANGELOG.md' )
9
11
. alias ( 'b' , 'branch' )
10
12
. nargs ( 'b' , 1 )
11
13
. describe ( 'b' , 'Specify non-master branch to release from' )
12
14
. help ( 'h' )
13
15
. alias ( 'h' , 'help' )
14
- . example ( '$0 --branch feature' , 'Release all packages from "feature" branch' )
16
+ . example ( '$0 --no-changelog -- branch feature' , 'Release all packages from "feature" branch' )
15
17
. argv ;
16
18
17
19
let path = require ( 'path' ) ;
@@ -36,17 +38,19 @@ projects = projects.reduce((memo, key) => { memo[key] = true; return memo; }, {}
36
38
echo ( '--> Checking working copy status...' ) ;
37
39
_exec ( `node ${ rootDir } /scripts/ensure_clean_master.js ${ argv . branch || 'master' } ` ) ;
38
40
39
- echo ( '--> Updating CHANGELOG...' ) ;
40
- _exec ( `node ${ rootDir } /scripts/update_changelog.js` ) ;
41
-
42
- echo ( '--> Committing changelog...' ) ;
43
- commands . push ( `` ) ;
44
- commands . push ( `` ) ;
45
- commands . push ( `################# To perform the release ################# ` ) ;
46
- commands . push ( `` ) ;
47
- commands . push ( `git commit -m "chore(*): Release prep - Update CHANGELOG" CHANGELOG.md` ) ;
48
- commands . push ( `git tag ${ version } ` ) ;
49
- commands . push ( `git push origin ${ version } ` ) ;
41
+ if ( ! argv [ 'no-changelog' ] ) {
42
+ echo ( '--> Updating CHANGELOG...' ) ;
43
+ _exec ( `node ${ rootDir } /scripts/update_changelog.js` ) ;
44
+
45
+ echo ( '--> Committing changelog...' ) ;
46
+ commands . push ( `` ) ;
47
+ commands . push ( `` ) ;
48
+ commands . push ( `################# To perform the release ################# ` ) ;
49
+ commands . push ( `` ) ;
50
+ commands . push ( `git commit -m "chore(*): Release prep - Update CHANGELOG" CHANGELOG.md` ) ;
51
+ commands . push ( `git tag ${ version } ` ) ;
52
+ commands . push ( `git push origin ${ version } ` ) ;
53
+ }
50
54
51
55
52
56
Object . keys ( projects ) . map ( project => {
0 commit comments