monorepo-next 9.4.5 → 9.4.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "monorepo-next",
3
- "version": "9.4.5",
3
+ "version": "9.4.7",
4
4
  "description": "Detach monorepo packages from normal linking",
5
5
  "bin": {
6
6
  "next": "bin/next.js"
@@ -119,7 +119,9 @@ async function firstPass({
119
119
 
120
120
  let releaseTree = await init({ dag, releaseTrees });
121
121
 
122
- releaseTree.releaseType = await module.exports.getReleaseType(name, cwd);
122
+ if (releaseTree[nextConfigSymbol].shouldBumpVersion) {
123
+ releaseTree.releaseType = await module.exports.getReleaseType(name, cwd);
124
+ }
123
125
  }
124
126
  }
125
127
 
@@ -189,6 +191,8 @@ async function secondPass({
189
191
  return;
190
192
  }
191
193
 
194
+ releaseTree[shouldVersionBumpSymbol]();
195
+
192
196
  for (let group of dag.node.dependents) {
193
197
  if (group.isCycle) {
194
198
  continue;
@@ -209,7 +213,6 @@ function thirdPass({
209
213
  releaseTrees,
210
214
  packagesWithChanges,
211
215
  shouldInheritGreaterReleaseType,
212
- shouldExcludeDevChanges,
213
216
  }) {
214
217
  for (let { dag, changedReleasableFiles } of packagesWithChanges) {
215
218
  if (!changedReleasableFiles.length) {
@@ -222,7 +225,7 @@ function thirdPass({
222
225
  }) {
223
226
  let current = releaseTrees[dag.node.packageName];
224
227
 
225
- if (!current) {
228
+ if (!current?.shouldBumpVersion) {
226
229
  return;
227
230
  }
228
231
 
@@ -236,12 +239,6 @@ function thirdPass({
236
239
 
237
240
  current.releaseType = currentReleaseType;
238
241
 
239
- let shouldVersionBump = !(shouldExcludeDevChanges && isDevDep);
240
-
241
- if (shouldVersionBump && current[nextConfigSymbol].shouldBumpVersion) {
242
- current[shouldVersionBumpSymbol]();
243
- }
244
-
245
242
  for (let group of dag.node.dependents) {
246
243
  if (group.isCycle) {
247
244
  continue;
@@ -353,7 +350,6 @@ async function buildReleaseGraph({
353
350
  releaseTrees,
354
351
  packagesWithChanges,
355
352
  shouldInheritGreaterReleaseType,
356
- shouldExcludeDevChanges,
357
353
  });
358
354
 
359
355
  // dependents have now inherited release type