@storm-software/git-tools 2.131.18 → 2.131.19
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/bin/git.cjs +30 -3
- package/bin/git.cjs.map +1 -1
- package/bin/git.js +30 -3
- package/bin/git.js.map +1 -1
- package/package.json +6 -6
package/bin/git.js
CHANGED
|
@@ -4275,7 +4275,7 @@ async function createReleaseGraph(options) {
|
|
|
4275
4275
|
await graph.init(options);
|
|
4276
4276
|
return graph;
|
|
4277
4277
|
}
|
|
4278
|
-
var StormReleaseGroupProcessor = class extends ReleaseGroupProcessor {
|
|
4278
|
+
var StormReleaseGroupProcessor = class _StormReleaseGroupProcessor extends ReleaseGroupProcessor {
|
|
4279
4279
|
constructor(tree, workspaceConfig, projectGraph, nxReleaseConfig, releaseGraph, versionOptions) {
|
|
4280
4280
|
super(tree, projectGraph, nxReleaseConfig, releaseGraph, {
|
|
4281
4281
|
dryRun: !!versionOptions.dryRun,
|
|
@@ -4296,6 +4296,16 @@ var StormReleaseGroupProcessor = class extends ReleaseGroupProcessor {
|
|
|
4296
4296
|
this.#nxReleaseConfig = nxReleaseConfig;
|
|
4297
4297
|
this.#releaseGraph = releaseGraph;
|
|
4298
4298
|
}
|
|
4299
|
+
static #BUMP_TYPE_PRIORITY = {
|
|
4300
|
+
major: 8,
|
|
4301
|
+
premajor: 7,
|
|
4302
|
+
minor: 6,
|
|
4303
|
+
preminor: 5,
|
|
4304
|
+
patch: 4,
|
|
4305
|
+
prepatch: 3,
|
|
4306
|
+
prerelease: 2,
|
|
4307
|
+
none: 1
|
|
4308
|
+
};
|
|
4299
4309
|
#tree;
|
|
4300
4310
|
#projectGraph;
|
|
4301
4311
|
#nxReleaseConfig;
|
|
@@ -4502,11 +4512,17 @@ var StormReleaseGroupProcessor = class extends ReleaseGroupProcessor {
|
|
|
4502
4512
|
newVersionInputReason,
|
|
4503
4513
|
newVersionInputReasonData
|
|
4504
4514
|
} = await this.#determineVersionBumpForProject(releaseGroup, project);
|
|
4505
|
-
if (!fixedGroup.currentVersion || currentVersion && semver.gt(currentVersion, fixedGroup.currentVersion) || !fixedGroup.newVersion || fixedGroup.newVersion.input === "none" ||
|
|
4515
|
+
if (!fixedGroup.currentVersion || currentVersion && semver.gt(currentVersion, fixedGroup.currentVersion) || !fixedGroup.newVersion || fixedGroup.newVersion.input === "none" || this.#isHigherPriorityBumpType(
|
|
4516
|
+
newVersionInput,
|
|
4517
|
+
fixedGroup.newVersion?.input
|
|
4518
|
+
)) {
|
|
4506
4519
|
if (!fixedGroup.currentVersion || currentVersion && semver.gt(currentVersion, fixedGroup.currentVersion)) {
|
|
4507
4520
|
fixedGroup.currentVersion = currentVersion;
|
|
4508
4521
|
}
|
|
4509
|
-
if (!fixedGroup.newVersion || fixedGroup.newVersion.input === "none" ||
|
|
4522
|
+
if (!fixedGroup.newVersion || fixedGroup.newVersion.input === "none" || this.#isHigherPriorityBumpType(
|
|
4523
|
+
newVersionInput,
|
|
4524
|
+
fixedGroup.newVersion?.input
|
|
4525
|
+
)) {
|
|
4510
4526
|
fixedGroup.newVersion = {
|
|
4511
4527
|
input: newVersionInput,
|
|
4512
4528
|
reason: newVersionInputReason,
|
|
@@ -4781,6 +4797,17 @@ var StormReleaseGroupProcessor = class extends ReleaseGroupProcessor {
|
|
|
4781
4797
|
}
|
|
4782
4798
|
return bumped;
|
|
4783
4799
|
}
|
|
4800
|
+
#isHigherPriorityBumpType(candidate, current) {
|
|
4801
|
+
const candidatePriority = _StormReleaseGroupProcessor.#BUMP_TYPE_PRIORITY[candidate];
|
|
4802
|
+
const currentPriority = _StormReleaseGroupProcessor.#BUMP_TYPE_PRIORITY[current];
|
|
4803
|
+
if (candidatePriority === void 0) {
|
|
4804
|
+
return false;
|
|
4805
|
+
}
|
|
4806
|
+
if (currentPriority === void 0) {
|
|
4807
|
+
return true;
|
|
4808
|
+
}
|
|
4809
|
+
return candidatePriority > currentPriority;
|
|
4810
|
+
}
|
|
4784
4811
|
#getCurrentCachedVersionForProject(projectName) {
|
|
4785
4812
|
return this.#releaseGraph.cachedCurrentVersions.get(projectName) || null;
|
|
4786
4813
|
}
|