Skip to content

Commit

Permalink
fix(assemble-release-plan): fixes bumping to major version when in pr…
Browse files Browse the repository at this point in the history
…e-release mode
  • Loading branch information
jgornick committed Apr 16, 2024
1 parent 0bf89b3 commit 518a9f0
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion packages/assemble-release-plan/src/determine-dependents.ts
Expand Up @@ -231,7 +231,12 @@ function shouldBumpMajor({
// 1. If onlyUpdatePeerDependentsWhenOutOfRange set to true, bump major if the version is leaving the range.
// 2. If onlyUpdatePeerDependentsWhenOutOfRange set to false, bump major regardless whether or not the version is leaving the range.
(!onlyUpdatePeerDependentsWhenOutOfRange ||
!semverSatisfies(incrementVersion(nextRelease, preInfo), versionRange)) &&
!semverSatisfies(
incrementVersion(nextRelease, preInfo),
versionRange,
// eslint-disable-next-line prettier/prettier
{ includePrerelease: preInfo !== undefined }
)) &&
// bump major only if the dependent doesn't already has a major release.
(!releases.has(dependent) ||
(releases.has(dependent) && releases.get(dependent)!.type !== "major"))
Expand Down

0 comments on commit 518a9f0

Please sign in to comment.