From 33ec9fdf47de4d8ab9d8ce43adedf4615dece4d9 Mon Sep 17 00:00:00 2001 From: Fabio Berger Date: Fri, 30 Mar 2018 15:49:09 +0200 Subject: Fixes for clarity --- packages/monorepo-scripts/src/publish.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'packages') diff --git a/packages/monorepo-scripts/src/publish.ts b/packages/monorepo-scripts/src/publish.ts index 905fee196..e2c0edff8 100644 --- a/packages/monorepo-scripts/src/publish.ts +++ b/packages/monorepo-scripts/src/publish.ts @@ -105,7 +105,7 @@ const semverNameToIndex: { [semver: string]: number } = { }); async function lernaPublishAsync(packageToVersionChange: { [name: string]: string }) { - // HACK: Lerna publish does not provide a way to specify multiple package versions as + // HACK: Lerna publish does not provide a way to specify multiple package versions via // flags so instead we need to interact with their interactive prompt interface. const child = spawn('lerna', ['publish', '--registry=https://registry.npmjs.org/'], { cwd: constants.monorepoRootPath, @@ -121,7 +121,8 @@ async function lernaPublishAsync(packageToVersionChange: { [name: string]: strin if (isPrivatePackage) { versionChange = 'patch'; // Always patch updates to private packages. } - child.stdin.write(`${semverNameToIndex[versionChange]}\n`); + const semVerIndex = semverNameToIndex[versionChange]; + child.stdin.write(`${semVerIndex}\n`); } const isFinalPrompt = _.includes(output, 'Are you sure you want to publish the above changes?'); if (isFinalPrompt && !IS_DRY_RUN) { -- cgit v1.2.3