From 71d15a68c1ca5de2055ad8c1ad9fc47608022a53 Mon Sep 17 00:00:00 2001 From: Fabio Berger Date: Wed, 21 Nov 2018 17:27:27 +0000 Subject: immediately return the patch incremented version if no changelog entries exist --- packages/monorepo-scripts/src/utils/utils.ts | 1 + 1 file changed, 1 insertion(+) (limited to 'packages/monorepo-scripts') diff --git a/packages/monorepo-scripts/src/utils/utils.ts b/packages/monorepo-scripts/src/utils/utils.ts index 44ff971e8..95b187cc2 100644 --- a/packages/monorepo-scripts/src/utils/utils.ts +++ b/packages/monorepo-scripts/src/utils/utils.ts @@ -91,6 +91,7 @@ export const utils = { const changelog = changelogUtils.getChangelogOrCreateIfMissing(packageName, packageLocation); if (_.isEmpty(changelog)) { nextVersionIfValid = semver.inc(currentVersion, 'patch'); + return nextVersionIfValid as string; } const lastEntry = changelog[0]; if (semver.gt(currentVersion, lastEntry.version)) { -- cgit v1.2.3 From 68c15de8908b1e8eb8f04d26301fec62ed2af1c1 Mon Sep 17 00:00:00 2001 From: Fabio Berger Date: Wed, 21 Nov 2018 17:27:40 +0000 Subject: print out error message and stack --- packages/monorepo-scripts/src/prepublish_checks.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'packages/monorepo-scripts') diff --git a/packages/monorepo-scripts/src/prepublish_checks.ts b/packages/monorepo-scripts/src/prepublish_checks.ts index fc550cf3a..60cdccf1d 100644 --- a/packages/monorepo-scripts/src/prepublish_checks.ts +++ b/packages/monorepo-scripts/src/prepublish_checks.ts @@ -195,6 +195,6 @@ const checkRequiredEnvVariables = () => { }; prepublishChecksAsync().catch(err => { - utils.log(err.message); + utils.log(err); process.exit(1); }); -- cgit v1.2.3