@lerna/batch-packages
Advanced tools
Comparing version 3.13.0 to 3.14.0
"use strict"; | ||
const log = require("npmlog"); | ||
const PackageGraph = require("@lerna/package-graph"); | ||
const ValidationError = require("@lerna/validation-error"); | ||
@@ -13,15 +11,7 @@ module.exports = batchPackages; | ||
const graph = new PackageGraph(packagesToBatch, graphType); | ||
const [cyclePaths, cycleNodes] = graph.partitionCycles(); | ||
const [cyclePaths, cycleNodes] = graph.partitionCycles(rejectCycles); | ||
const batches = []; | ||
if (cyclePaths.size) { | ||
const cycleMessage = ["Dependency cycles detected, you should fix these!"] | ||
.concat(Array.from(cyclePaths).map(cycle => cycle.join(" -> "))) | ||
.join("\n"); | ||
if (rejectCycles) { | ||
throw new ValidationError("ECYCLE", cycleMessage); | ||
} | ||
log.warn("ECYCLE", cycleMessage); | ||
graph.pruneCycleNodes(cycleNodes); | ||
} | ||
@@ -28,0 +18,0 @@ |
@@ -6,2 +6,13 @@ # Change Log | ||
# [3.14.0](https://github.com/lerna/lerna/compare/v3.13.4...v3.14.0) (2019-05-14) | ||
### Features | ||
* **run:** Add just-in-time queue management ([#2045](https://github.com/lerna/lerna/issues/2045)) ([6eca172](https://github.com/lerna/lerna/commit/6eca172)) | ||
# [3.13.0](https://github.com/lerna/lerna/compare/v3.12.1...v3.13.0) (2019-02-15) | ||
@@ -8,0 +19,0 @@ |
{ | ||
"name": "@lerna/batch-packages", | ||
"version": "3.13.0", | ||
"version": "3.14.0", | ||
"description": "An internal Lerna tool", | ||
@@ -34,7 +34,6 @@ "keywords": [ | ||
"dependencies": { | ||
"@lerna/package-graph": "3.13.0", | ||
"@lerna/validation-error": "3.13.0", | ||
"@lerna/package-graph": "3.14.0", | ||
"npmlog": "^4.1.2" | ||
}, | ||
"gitHead": "9a47201f3fdd1df09cfb1922f26329d1dc4c8cc5" | ||
"gitHead": "39da145c67ea587457694f318f32f967b9d66ea9" | ||
} |
2
6607
31
+ Added@lerna/package-graph@3.14.0(transitive)
+ Added@lerna/prerelease-id-from-version@3.14.0(transitive)
- Removed@lerna/validation-error@3.13.0
- Removed@lerna/package-graph@3.13.0(transitive)
Updated@lerna/package-graph@3.14.0