feat: allow to release from local machine

This commit is contained in:
Pierre Vanduynslager
2018-01-02 14:31:43 -05:00
parent 5cc62e49ee
commit 5bc46a08cf
4 changed files with 64 additions and 6 deletions
+3 -3
View File
@@ -10,13 +10,13 @@ const {gitHead: getGitHead, isGitRepo} = require('./lib/git');
module.exports = async opts => {
const {isCi, branch, isPr} = envCi();
if (!isCi && !opts.dryRun) {
if (!isCi && !opts.dryRun && !opts.noCi) {
logger.log('This run was not triggered in a known CI environment, running in dry-run mode.');
opts.dryRun = true;
}
if (isCi && isPr) {
logger.log('This run was triggered by a pull request and therefore a new version wont be published.');
if (isCi && isPr && !opts.noCi) {
logger.log("This run was triggered by a pull request and therefore a new version won't be published.");
return;
}