Skip to content

Commit

Permalink
Merge pull request #207 from HubSpot/add-back-release-checks
Browse files Browse the repository at this point in the history
Restore check for local and npm version sync in release script
  • Loading branch information
camden11 authored Nov 12, 2024
2 parents 30caca7 + 63cbe76 commit cbe7fb0
Showing 1 changed file with 11 additions and 15 deletions.
26 changes: 11 additions & 15 deletions scripts/release.ts
Original file line number Diff line number Diff line change
Expand Up @@ -133,21 +133,17 @@ async function handler({
process.exit(EXIT_CODES.ERROR);
}

const {
// next: currentNextTag,
experimental: currentExperimentalTag,
} = await getDistTags();

// if (!isExperimental && currentNextTag !== localVersion) {
// logger.error(
// `Local package.json version ${localVersion} is out of sync with published version ${currentNextTag}`
// );
// process.exit(EXIT_CODES.ERROR);
// }

const currentVersion = isExperimental
? currentExperimentalTag || '0.0.0'
: localVersion;
const { next: currentNextTag, experimental: currentExperimentalTag } =
await getDistTags();

if (!isExperimental && currentNextTag !== localVersion) {
logger.error(
`Local package.json version ${localVersion} is out of sync with published version ${currentNextTag}`
);
process.exit(EXIT_CODES.ERROR);
}

const currentVersion = isExperimental ? currentExperimentalTag : localVersion;
const prereleaseIdentifier = isExperimental
? PRERELEASE_IDENTIFIER.EXPERIMENTAL
: PRERELEASE_IDENTIFIER.NEXT;
Expand Down

0 comments on commit cbe7fb0

Please sign in to comment.