Skip to content

Commit 446b31e

Browse files
authored
Merge pull request #5467 from plotly/use-tag-in-post-publish
post publish using tag from the package version
2 parents aef5c50 + 4d1500a commit 446b31e

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

tasks/sync_packages.js

+3-1
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ var glob = require('glob');
77
var common = require('./util/common');
88
var constants = require('./util/constants');
99
var pkg = require('../package.json');
10+
var rc = pkg.version.split('-')[1];
11+
var tag = rc ? (' --tag ' + rc.split('.')[0]) : '';
1012

1113
var year = (new Date()).getFullYear();
1214

@@ -306,6 +308,6 @@ function _publishToNPM(d, pkgPath) {
306308
cb();
307309
return;
308310
}
309-
exec('npm publish', {cwd: pkgPath}, cb).stdout.pipe(process.stdout);
311+
exec('npm publish' + tag, {cwd: pkgPath}, cb).stdout.pipe(process.stdout);
310312
};
311313
}

0 commit comments

Comments
 (0)