aboutsummaryrefslogtreecommitdiffstats
path: root/packages/monorepo-scripts/src/publish.ts
diff options
context:
space:
mode:
authorFabio Berger <me@fabioberger.com>2018-07-24 02:59:41 +0800
committerFabio Berger <me@fabioberger.com>2018-07-24 02:59:41 +0800
commitbfe57b84d600c0d4aaa8b7a22323de6051f0751c (patch)
treee7aeb4da7d732ec6c55f4de6aaaf0a1c84973c57 /packages/monorepo-scripts/src/publish.ts
parentdae975b08c23d1ad81be72f46ae64f59406953ab (diff)
downloaddexon-0x-contracts-bfe57b84d600c0d4aaa8b7a22323de6051f0751c.tar.gz
dexon-0x-contracts-bfe57b84d600c0d4aaa8b7a22323de6051f0751c.tar.zst
dexon-0x-contracts-bfe57b84d600c0d4aaa8b7a22323de6051f0751c.zip
Use string equals and remove returns
Diffstat (limited to 'packages/monorepo-scripts/src/publish.ts')
-rw-r--r--packages/monorepo-scripts/src/publish.ts4
1 files changed, 1 insertions, 3 deletions
diff --git a/packages/monorepo-scripts/src/publish.ts b/packages/monorepo-scripts/src/publish.ts
index 1bdf5c218..af707ca47 100644
--- a/packages/monorepo-scripts/src/publish.ts
+++ b/packages/monorepo-scripts/src/publish.ts
@@ -198,16 +198,14 @@ async function lernaPublishAsync(packageToNextVersion: { [name: string]: string
const outputStripLeft = output.split('new version for ')[1];
packageName = outputStripLeft.split(' ')[0];
child.stdin.write(`${SemVerIndex.Custom}\n`);
- return;
}
- const isCustomVersionPrompt = _.includes(output, 'Enter a custom version');
+ const isCustomVersionPrompt = output === '? Enter a custom version ';
if (isCustomVersionPrompt) {
const versionChange = packageToNextVersion[packageName];
if (_.isUndefined(versionChange)) {
throw new Error(`Must have a nextVersion for each packageName. Didn't find one for ${packageName}`);
}
child.stdin.write(`${versionChange}\n`);
- return;
}
const isFinalPrompt = _.includes(output, 'Are you sure you want to publish the above changes?');
if (isFinalPrompt && !IS_DRY_RUN) {