Skip to content

Commit

Permalink
Merge pull request #5467 from plotly/use-tag-in-post-publish
Browse files Browse the repository at this point in the history
post publish using tag from the package version
  • Loading branch information
archmoj authored Feb 3, 2021
2 parents aef5c50 + 4d1500a commit 446b31e
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion tasks/sync_packages.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ var glob = require('glob');
var common = require('./util/common');
var constants = require('./util/constants');
var pkg = require('../package.json');
var rc = pkg.version.split('-')[1];
var tag = rc ? (' --tag ' + rc.split('.')[0]) : '';

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

Expand Down Expand Up @@ -306,6 +308,6 @@ function _publishToNPM(d, pkgPath) {
cb();
return;
}
exec('npm publish', {cwd: pkgPath}, cb).stdout.pipe(process.stdout);
exec('npm publish' + tag, {cwd: pkgPath}, cb).stdout.pipe(process.stdout);
};
}

0 comments on commit 446b31e

Please sign in to comment.