@storm-software/git-tools 2.131.126 → 2.131.128
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/README.md +1 -1
- package/bin/{chunk-GAHICIOD.js → chunk-A5X7CY3W.js} +3 -3
- package/bin/{chunk-GAHICIOD.js.map → chunk-A5X7CY3W.js.map} +1 -1
- package/bin/{chunk-ZBZINLOA.js → chunk-AOZSGQGA.js} +3 -3
- package/bin/{chunk-ZBZINLOA.js.map → chunk-AOZSGQGA.js.map} +1 -1
- package/bin/chunk-FOMBLMLH.js +2073 -0
- package/bin/chunk-FOMBLMLH.js.map +1 -0
- package/bin/{chunk-B5CZCP2Y.cjs → chunk-GT7HITVF.cjs} +4 -4
- package/bin/{chunk-B5CZCP2Y.cjs.map → chunk-GT7HITVF.cjs.map} +1 -1
- package/bin/{chunk-ZL2JPPJF.cjs → chunk-IHDSESSE.cjs} +4 -4
- package/bin/{chunk-ZL2JPPJF.cjs.map → chunk-IHDSESSE.cjs.map} +1 -1
- package/bin/{chunk-SASCLX6I.js → chunk-IIH7F7OZ.js} +3 -3
- package/bin/{chunk-SASCLX6I.js.map → chunk-IIH7F7OZ.js.map} +1 -1
- package/bin/{chunk-KFRB3UCF.js → chunk-JBHMFR7F.js} +3 -3
- package/bin/{chunk-KFRB3UCF.js.map → chunk-JBHMFR7F.js.map} +1 -1
- package/bin/{chunk-KJMWPKRH.cjs → chunk-JYYYVLIU.cjs} +4 -4
- package/bin/{chunk-KJMWPKRH.cjs.map → chunk-JYYYVLIU.cjs.map} +1 -1
- package/bin/{chunk-MUNEGKNC.cjs → chunk-ML5MZIGJ.cjs} +5 -5
- package/bin/{chunk-MUNEGKNC.cjs.map → chunk-ML5MZIGJ.cjs.map} +1 -1
- package/bin/{chunk-NNIW4L2Q.js → chunk-NG23E43K.js} +3 -3
- package/bin/{chunk-NNIW4L2Q.js.map → chunk-NG23E43K.js.map} +1 -1
- package/bin/{chunk-2NTFR3EF.cjs → chunk-QBI7KQ6A.cjs} +6 -6
- package/bin/{chunk-2NTFR3EF.cjs.map → chunk-QBI7KQ6A.cjs.map} +1 -1
- package/bin/{chunk-VIFL2F7H.js → chunk-SHH572XU.js} +3 -3
- package/bin/{chunk-VIFL2F7H.js.map → chunk-SHH572XU.js.map} +1 -1
- package/bin/{chunk-NZ4HDNJ7.cjs → chunk-SZFP3TKI.cjs} +4 -4
- package/bin/{chunk-NZ4HDNJ7.cjs.map → chunk-SZFP3TKI.cjs.map} +1 -1
- package/bin/chunk-TOLGVHZM.cjs +2116 -0
- package/bin/chunk-TOLGVHZM.cjs.map +1 -0
- package/bin/{chunk-MSQDEBW3.js → chunk-WUN4N3D7.js} +3 -3
- package/bin/{chunk-MSQDEBW3.js.map → chunk-WUN4N3D7.js.map} +1 -1
- package/bin/{chunk-IXUKWNVT.cjs → chunk-ZJN2D7NE.cjs} +4 -4
- package/bin/{chunk-IXUKWNVT.cjs.map → chunk-ZJN2D7NE.cjs.map} +1 -1
- package/bin/git.cjs +185 -195
- package/bin/git.cjs.map +1 -1
- package/bin/git.js +46 -54
- package/bin/git.js.map +1 -1
- package/bin/post-checkout.cjs +7 -7
- package/bin/post-checkout.js +2 -2
- package/bin/post-commit.cjs +7 -7
- package/bin/post-commit.js +2 -2
- package/bin/post-merge.cjs +7 -7
- package/bin/post-merge.js +2 -2
- package/bin/pre-commit.cjs +7 -7
- package/bin/pre-commit.js +2 -2
- package/bin/pre-install.cjs +7 -7
- package/bin/pre-install.js +2 -2
- package/bin/pre-push.cjs +7 -7
- package/bin/pre-push.js +2 -2
- package/bin/prepare.cjs +7 -7
- package/bin/prepare.js +2 -2
- package/bin/version-warning.cjs +5 -5
- package/bin/version-warning.js +1 -1
- package/dist/chunk-52Z6PKZI.js +2412 -0
- package/dist/chunk-U5IGP2SZ.cjs +2454 -0
- package/dist/index.cjs +18 -18
- package/dist/index.js +1 -1
- package/dist/release/config.cjs +18 -18
- package/dist/release/config.js +1 -1
- package/package.json +10 -14
- package/bin/chunk-DGRFGD2R.cjs +0 -3578
- package/bin/chunk-DGRFGD2R.cjs.map +0 -1
- package/bin/chunk-ZW42VDY5.js +0 -3554
- package/bin/chunk-ZW42VDY5.js.map +0 -1
- package/dist/chunk-IVBFLZSL.cjs +0 -3863
- package/dist/chunk-J5FHPMMG.js +0 -3840
package/bin/git.cjs
CHANGED
|
@@ -1,32 +1,24 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
'use strict';
|
|
3
3
|
|
|
4
|
-
var
|
|
5
|
-
var
|
|
6
|
-
var
|
|
7
|
-
var
|
|
8
|
-
require('./chunk-
|
|
9
|
-
var
|
|
4
|
+
var chunkIHDSESSE_cjs = require('./chunk-IHDSESSE.cjs');
|
|
5
|
+
var chunkGT7HITVF_cjs = require('./chunk-GT7HITVF.cjs');
|
|
6
|
+
var chunkSZFP3TKI_cjs = require('./chunk-SZFP3TKI.cjs');
|
|
7
|
+
var chunkZJN2D7NE_cjs = require('./chunk-ZJN2D7NE.cjs');
|
|
8
|
+
require('./chunk-ML5MZIGJ.cjs');
|
|
9
|
+
var chunkQBI7KQ6A_cjs = require('./chunk-QBI7KQ6A.cjs');
|
|
10
10
|
require('./chunk-SP3UCTLI.cjs');
|
|
11
|
-
var
|
|
11
|
+
var chunkJYYYVLIU_cjs = require('./chunk-JYYYVLIU.cjs');
|
|
12
12
|
var chunkMTAYUS7E_cjs = require('./chunk-MTAYUS7E.cjs');
|
|
13
|
-
var
|
|
13
|
+
var chunkTOLGVHZM_cjs = require('./chunk-TOLGVHZM.cjs');
|
|
14
14
|
var TOML = require('@ltd/j-toml');
|
|
15
15
|
var commander = require('commander');
|
|
16
|
-
require('@inquirer/
|
|
17
|
-
require('@inquirer/editor');
|
|
18
|
-
var default4 = require('@inquirer/confirm');
|
|
19
|
-
var default5 = require('@inquirer/input');
|
|
20
|
-
require('@inquirer/number');
|
|
21
|
-
require('@inquirer/expand');
|
|
22
|
-
require('@inquirer/rawlist');
|
|
23
|
-
require('@inquirer/password');
|
|
24
|
-
require('@inquirer/search');
|
|
25
|
-
var default11 = require('@inquirer/select');
|
|
16
|
+
var prompts = require('@inquirer/prompts');
|
|
26
17
|
var shellescape = require('any-shell-escape');
|
|
27
18
|
var chalk2 = require('chalk');
|
|
28
19
|
var fs = require('fs/promises');
|
|
29
20
|
var createBasePreset = require('conventional-changelog-conventionalcommits');
|
|
21
|
+
var defu3 = require('defu');
|
|
30
22
|
var projectGraph = require('nx/src/project-graph/project-graph');
|
|
31
23
|
var fs$1 = require('fs');
|
|
32
24
|
var childProcess = require('child_process');
|
|
@@ -78,13 +70,11 @@ var releaseGroupProcessor = require('nx/src/command-line/release/version/release
|
|
|
78
70
|
function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }
|
|
79
71
|
|
|
80
72
|
var TOML__default = /*#__PURE__*/_interopDefault(TOML);
|
|
81
|
-
var default4__default = /*#__PURE__*/_interopDefault(default4);
|
|
82
|
-
var default5__default = /*#__PURE__*/_interopDefault(default5);
|
|
83
|
-
var default11__default = /*#__PURE__*/_interopDefault(default11);
|
|
84
73
|
var shellescape__default = /*#__PURE__*/_interopDefault(shellescape);
|
|
85
74
|
var chalk2__default = /*#__PURE__*/_interopDefault(chalk2);
|
|
86
75
|
var fs__default = /*#__PURE__*/_interopDefault(fs);
|
|
87
76
|
var createBasePreset__default = /*#__PURE__*/_interopDefault(createBasePreset);
|
|
77
|
+
var defu3__default = /*#__PURE__*/_interopDefault(defu3);
|
|
88
78
|
var childProcess__default = /*#__PURE__*/_interopDefault(childProcess);
|
|
89
79
|
var defaultRules__default = /*#__PURE__*/_interopDefault(defaultRules);
|
|
90
80
|
var util__default = /*#__PURE__*/_interopDefault(util);
|
|
@@ -425,9 +415,9 @@ function getRuleFromScopeEnum(scopeEnum) {
|
|
|
425
415
|
|
|
426
416
|
// ../conventional-changelog/src/index.ts
|
|
427
417
|
async function createPreset(variant = "monorepo") {
|
|
428
|
-
const workspaceConfig = await
|
|
418
|
+
const workspaceConfig = await chunkTOLGVHZM_cjs.getWorkspaceConfig();
|
|
429
419
|
if (variant === "minimal") {
|
|
430
|
-
return
|
|
420
|
+
return defu3__default.default(
|
|
431
421
|
await createBasePreset__default.default({ ...COMMIT_CONFIGS.minimal.changelogs.props }),
|
|
432
422
|
{
|
|
433
423
|
...COMMIT_CONFIGS.minimal,
|
|
@@ -441,7 +431,7 @@ async function createPreset(variant = "monorepo") {
|
|
|
441
431
|
);
|
|
442
432
|
}
|
|
443
433
|
const nxScopes = await getNxScopes({ config: workspaceConfig });
|
|
444
|
-
return
|
|
434
|
+
return defu3__default.default(
|
|
445
435
|
await createBasePreset__default.default({
|
|
446
436
|
...COMMIT_CONFIGS.monorepo.changelogs.props,
|
|
447
437
|
scope: nxScopes
|
|
@@ -509,17 +499,17 @@ function getParserRegexes(options = {}) {
|
|
|
509
499
|
|
|
510
500
|
// ../../node_modules/.pnpm/conventional-commits-parser@6.4.0/node_modules/conventional-commits-parser/dist/utils.js
|
|
511
501
|
var SCISSOR = "------------------------ >8 ------------------------";
|
|
512
|
-
function trimNewLines(
|
|
513
|
-
const matches =
|
|
502
|
+
function trimNewLines(input2) {
|
|
503
|
+
const matches = input2.match(/[^\r\n]/);
|
|
514
504
|
if (typeof matches?.index !== "number") {
|
|
515
505
|
return "";
|
|
516
506
|
}
|
|
517
507
|
const firstIndex = matches.index;
|
|
518
|
-
let lastIndex =
|
|
519
|
-
while (
|
|
508
|
+
let lastIndex = input2.length - 1;
|
|
509
|
+
while (input2[lastIndex] === "\r" || input2[lastIndex] === "\n") {
|
|
520
510
|
lastIndex--;
|
|
521
511
|
}
|
|
522
|
-
return
|
|
512
|
+
return input2.substring(firstIndex, lastIndex + 1);
|
|
523
513
|
}
|
|
524
514
|
function appendLine(src, line) {
|
|
525
515
|
return src ? `${src}
|
|
@@ -609,12 +599,12 @@ var CommitParser = class {
|
|
|
609
599
|
isLineAvailable() {
|
|
610
600
|
return this.lineIndex < this.lines.length;
|
|
611
601
|
}
|
|
612
|
-
parseReference(
|
|
602
|
+
parseReference(input2, action) {
|
|
613
603
|
const { regexes } = this;
|
|
614
|
-
if (regexes.url.test(
|
|
604
|
+
if (regexes.url.test(input2)) {
|
|
615
605
|
return null;
|
|
616
606
|
}
|
|
617
|
-
const matches = regexes.referenceParts.exec(
|
|
607
|
+
const matches = regexes.referenceParts.exec(input2);
|
|
618
608
|
if (!matches) {
|
|
619
609
|
return null;
|
|
620
610
|
}
|
|
@@ -636,16 +626,16 @@ var CommitParser = class {
|
|
|
636
626
|
issue
|
|
637
627
|
};
|
|
638
628
|
}
|
|
639
|
-
parseReferences(
|
|
629
|
+
parseReferences(input2) {
|
|
640
630
|
const { regexes } = this;
|
|
641
|
-
const regex =
|
|
631
|
+
const regex = input2.match(regexes.references) ? regexes.references : /()(.+)/gi;
|
|
642
632
|
const references = [];
|
|
643
633
|
let matches;
|
|
644
634
|
let action;
|
|
645
635
|
let sentence;
|
|
646
636
|
let reference;
|
|
647
637
|
while (true) {
|
|
648
|
-
matches = regex.exec(
|
|
638
|
+
matches = regex.exec(input2);
|
|
649
639
|
if (!matches) {
|
|
650
640
|
break;
|
|
651
641
|
}
|
|
@@ -796,21 +786,21 @@ var CommitParser = class {
|
|
|
796
786
|
});
|
|
797
787
|
}
|
|
798
788
|
}
|
|
799
|
-
parseMentions(
|
|
789
|
+
parseMentions(input2) {
|
|
800
790
|
const { commit, regexes } = this;
|
|
801
791
|
let matches;
|
|
802
792
|
for (; ; ) {
|
|
803
|
-
matches = regexes.mentions.exec(
|
|
793
|
+
matches = regexes.mentions.exec(input2);
|
|
804
794
|
if (!matches) {
|
|
805
795
|
break;
|
|
806
796
|
}
|
|
807
797
|
commit.mentions.push(matches[1]);
|
|
808
798
|
}
|
|
809
799
|
}
|
|
810
|
-
parseRevert(
|
|
800
|
+
parseRevert(input2) {
|
|
811
801
|
const { commit, options } = this;
|
|
812
802
|
const correspondence = options.revertCorrespondence || [];
|
|
813
|
-
const matches = options.revertPattern ?
|
|
803
|
+
const matches = options.revertPattern ? input2.match(options.revertPattern) : null;
|
|
814
804
|
if (matches) {
|
|
815
805
|
commit.revert = assignMatchedCorrespondence({}, matches, correspondence);
|
|
816
806
|
}
|
|
@@ -841,13 +831,13 @@ var CommitParser = class {
|
|
|
841
831
|
* @param input - Commit message string.
|
|
842
832
|
* @returns Commit object.
|
|
843
833
|
*/
|
|
844
|
-
parse(
|
|
845
|
-
if (!
|
|
834
|
+
parse(input2) {
|
|
835
|
+
if (!input2.trim()) {
|
|
846
836
|
throw new TypeError("Expected a raw commit");
|
|
847
837
|
}
|
|
848
838
|
const { commentChar } = this.options;
|
|
849
839
|
const commentFilter = getCommentFilter(commentChar);
|
|
850
|
-
const rawLines = trimNewLines(
|
|
840
|
+
const rawLines = trimNewLines(input2).split(/\r?\n/);
|
|
851
841
|
const lines = commentChar ? truncateToScissor(rawLines, commentChar).filter((line) => commentFilter(line) && gpgFilter(line)) : rawLines.filter((line) => gpgFilter(line));
|
|
852
842
|
const commit = createCommitObject();
|
|
853
843
|
this.lines = lines;
|
|
@@ -869,8 +859,8 @@ var CommitParser = class {
|
|
|
869
859
|
}
|
|
870
860
|
}
|
|
871
861
|
this.parseBreakingHeader();
|
|
872
|
-
this.parseMentions(
|
|
873
|
-
this.parseRevert(
|
|
862
|
+
this.parseMentions(input2);
|
|
863
|
+
this.parseRevert(input2);
|
|
874
864
|
this.cleanupCommit();
|
|
875
865
|
return commit;
|
|
876
866
|
}
|
|
@@ -1005,7 +995,7 @@ async function lint(message, config5) {
|
|
|
1005
995
|
// src/commitlint/run.ts
|
|
1006
996
|
var COMMIT_EDITMSG_PATH = ".git/COMMIT_EDITMSG";
|
|
1007
997
|
async function runCommitLint(workspaceConfig, options) {
|
|
1008
|
-
|
|
998
|
+
chunkTOLGVHZM_cjs.writeInfo(
|
|
1009
999
|
"\u{1F4DD} Validating git commit message aligns with the Storm Software specification",
|
|
1010
1000
|
workspaceConfig
|
|
1011
1001
|
);
|
|
@@ -1013,7 +1003,7 @@ async function runCommitLint(workspaceConfig, options) {
|
|
|
1013
1003
|
if (options.message && options.message !== COMMIT_EDITMSG_PATH) {
|
|
1014
1004
|
commitMessage = options.message;
|
|
1015
1005
|
} else {
|
|
1016
|
-
const commitFile =
|
|
1006
|
+
const commitFile = chunkTOLGVHZM_cjs.joinPaths(
|
|
1017
1007
|
workspaceConfig.workspaceRoot,
|
|
1018
1008
|
options.file || options.message || COMMIT_EDITMSG_PATH
|
|
1019
1009
|
);
|
|
@@ -1030,17 +1020,17 @@ async function runCommitLint(workspaceConfig, options) {
|
|
|
1030
1020
|
if (upstreamRemote) {
|
|
1031
1021
|
const upstreamRemoteIdentifier = upstreamRemote.split(" ")[0]?.trim();
|
|
1032
1022
|
if (!upstreamRemoteIdentifier) {
|
|
1033
|
-
|
|
1023
|
+
chunkTOLGVHZM_cjs.writeWarning(
|
|
1034
1024
|
`No upstream remote found for ${workspaceConfig.name}.git. Skipping comparison.`,
|
|
1035
1025
|
workspaceConfig
|
|
1036
1026
|
);
|
|
1037
1027
|
return;
|
|
1038
1028
|
}
|
|
1039
|
-
|
|
1029
|
+
chunkTOLGVHZM_cjs.writeDebug(`Comparing against remote ${upstreamRemoteIdentifier}`);
|
|
1040
1030
|
const currentBranch = childProcess__default.default.execSync("git branch --show-current").toString().trim();
|
|
1041
1031
|
gitLogCmd = gitLogCmd + ` ${currentBranch} ^${upstreamRemoteIdentifier}/main`;
|
|
1042
1032
|
} else {
|
|
1043
|
-
|
|
1033
|
+
chunkTOLGVHZM_cjs.writeWarning(
|
|
1044
1034
|
`No upstream remote found for ${workspaceConfig.name}.git. Skipping comparison against upstream main.`,
|
|
1045
1035
|
workspaceConfig
|
|
1046
1036
|
);
|
|
@@ -1048,7 +1038,7 @@ async function runCommitLint(workspaceConfig, options) {
|
|
|
1048
1038
|
}
|
|
1049
1039
|
commitMessage = childProcess__default.default.execSync(gitLogCmd).toString().trim();
|
|
1050
1040
|
if (!commitMessage) {
|
|
1051
|
-
|
|
1041
|
+
chunkTOLGVHZM_cjs.writeWarning(
|
|
1052
1042
|
"No commits found. Skipping commit message validation.",
|
|
1053
1043
|
workspaceConfig
|
|
1054
1044
|
);
|
|
@@ -1058,7 +1048,7 @@ async function runCommitLint(workspaceConfig, options) {
|
|
|
1058
1048
|
const preset = await createPreset(workspaceConfig.variant);
|
|
1059
1049
|
const report = await lint(commitMessage, preset);
|
|
1060
1050
|
if (!preset.commitlint.regex.test(commitMessage) || report.errors.length || report.warnings.length) {
|
|
1061
|
-
|
|
1051
|
+
chunkTOLGVHZM_cjs.writeSuccess(
|
|
1062
1052
|
`Commit was processing completed successfully!`,
|
|
1063
1053
|
workspaceConfig
|
|
1064
1054
|
);
|
|
@@ -1270,7 +1260,7 @@ async function createState(workspaceConfig, configPath) {
|
|
|
1270
1260
|
const project = projectConfigurations.projects[scope];
|
|
1271
1261
|
if (project) {
|
|
1272
1262
|
let description = `${project.name} - ${project.root}`;
|
|
1273
|
-
const packageJsonPath =
|
|
1263
|
+
const packageJsonPath = chunkTOLGVHZM_cjs.joinPaths(project.root, "package.json");
|
|
1274
1264
|
if (fs$1.existsSync(packageJsonPath)) {
|
|
1275
1265
|
const packageJsonFile = await fs.readFile(packageJsonPath, "utf8");
|
|
1276
1266
|
const packageJson = JSON.parse(packageJsonFile);
|
|
@@ -1344,19 +1334,19 @@ ${closedIssueEmoji}${config5.settings.closedIssueMessage}${issues}`;
|
|
|
1344
1334
|
|
|
1345
1335
|
// src/commit/run.ts
|
|
1346
1336
|
async function runCommit(commitizenFile, dryRun = false) {
|
|
1347
|
-
const workspaceConfig = await
|
|
1337
|
+
const workspaceConfig = await chunkTOLGVHZM_cjs.getWorkspaceConfig();
|
|
1348
1338
|
const state = await createState(workspaceConfig);
|
|
1349
1339
|
if (dryRun) {
|
|
1350
|
-
|
|
1340
|
+
chunkTOLGVHZM_cjs.writeInfo("Running in dry mode.", workspaceConfig);
|
|
1351
1341
|
}
|
|
1352
1342
|
console.log(
|
|
1353
1343
|
chalk2__default.default.bold.hex("#4b585b")("----------------------------------------") + "\n" + chalk2__default.default.bold.hex("#FFFFFF")(
|
|
1354
|
-
` ${
|
|
1344
|
+
` ${chunkTOLGVHZM_cjs.brandIcon(workspaceConfig)} Storm Software Git-Tools - Commit`
|
|
1355
1345
|
) + "\n" + chalk2__default.default.hex("#9ca8ab")("Please provide the requested details below...") + "\n"
|
|
1356
1346
|
);
|
|
1357
1347
|
state.answers = await askQuestions(state);
|
|
1358
1348
|
const message = formatCommitMessage(state, workspaceConfig);
|
|
1359
|
-
const commitMsgFile =
|
|
1349
|
+
const commitMsgFile = chunkTOLGVHZM_cjs.joinPaths(getGitDir(), "COMMIT_EDITMSG");
|
|
1360
1350
|
console.log(
|
|
1361
1351
|
chalk2__default.default.bold.hex("#4b585b")("----------------------------------------") + `
|
|
1362
1352
|
|
|
@@ -1373,11 +1363,11 @@ ${chalk2__default.default.bold.hex("#FFFFFF")("Git-Commit File")}${chalk2__defau
|
|
|
1373
1363
|
commandItems.push(...["--file", commitMsgFile]);
|
|
1374
1364
|
const command = shellescape__default.default(commandItems);
|
|
1375
1365
|
if (dryRun) {
|
|
1376
|
-
|
|
1366
|
+
chunkTOLGVHZM_cjs.writeDebug(
|
|
1377
1367
|
`Skipping execution [dry-run]: ${command.replace(commitMsgFile, ".git/COMMIT_EDITMSG")}`,
|
|
1378
1368
|
workspaceConfig
|
|
1379
1369
|
);
|
|
1380
|
-
|
|
1370
|
+
chunkTOLGVHZM_cjs.writeDebug(`Message [dry-run]: ${message}`, workspaceConfig);
|
|
1381
1371
|
} else {
|
|
1382
1372
|
await fs__default.default.writeFile(commitMsgFile, message);
|
|
1383
1373
|
chunkMTAYUS7E_cjs.run(workspaceConfig, command);
|
|
@@ -1402,7 +1392,7 @@ async function askQuestion(index, question) {
|
|
|
1402
1392
|
)} - ${question.description}
|
|
1403
1393
|
`;
|
|
1404
1394
|
if (question.type === "select" && question.enum && Object.keys(question.enum).length > 1) {
|
|
1405
|
-
return
|
|
1395
|
+
return prompts.select({
|
|
1406
1396
|
message,
|
|
1407
1397
|
choices: Object.keys(question.enum).filter((key) => !question.enum?.[key]?.hidden).map((key) => ({
|
|
1408
1398
|
name: question.enum?.[key]?.title || key,
|
|
@@ -1412,7 +1402,7 @@ async function askQuestion(index, question) {
|
|
|
1412
1402
|
default: String(question.defaultValue || "")
|
|
1413
1403
|
});
|
|
1414
1404
|
} else if (question.type === "confirm") {
|
|
1415
|
-
return
|
|
1405
|
+
return prompts.confirm({
|
|
1416
1406
|
message,
|
|
1417
1407
|
default: Boolean(question.defaultValue)
|
|
1418
1408
|
});
|
|
@@ -1429,7 +1419,7 @@ async function askQuestion(index, question) {
|
|
|
1429
1419
|
return true;
|
|
1430
1420
|
};
|
|
1431
1421
|
}
|
|
1432
|
-
return
|
|
1422
|
+
return prompts.input({
|
|
1433
1423
|
message,
|
|
1434
1424
|
required: !!(question.minLength !== void 0 && question.minLength > 0),
|
|
1435
1425
|
default: String(question.defaultValue || ""),
|
|
@@ -2038,7 +2028,7 @@ var runReadme = async ({
|
|
|
2038
2028
|
exitOnError: true
|
|
2039
2029
|
});
|
|
2040
2030
|
const projectConfigs = projectGraph.readProjectsConfigurationFromProjectGraph(projectGraph$1);
|
|
2041
|
-
const workspaceRoot =
|
|
2031
|
+
const workspaceRoot = chunkTOLGVHZM_cjs.findWorkspaceRootSafe(process.cwd());
|
|
2042
2032
|
if (!workspaceRoot) {
|
|
2043
2033
|
throw new Error(
|
|
2044
2034
|
"Unable to find the workspace root. Please ensure you are running this command from within a workspace."
|
|
@@ -2432,9 +2422,9 @@ var LOWER_CASE_WHEN_NOT_FIRST = [
|
|
|
2432
2422
|
"at",
|
|
2433
2423
|
"by"
|
|
2434
2424
|
];
|
|
2435
|
-
function titleCase(
|
|
2436
|
-
if (!
|
|
2437
|
-
return
|
|
2425
|
+
function titleCase(input2) {
|
|
2426
|
+
if (!input2) {
|
|
2427
|
+
return input2;
|
|
2438
2428
|
}
|
|
2439
2429
|
const formatSegment = (segment) => segment.toLowerCase().split(/[\s\-_]+/).filter(Boolean).map((word, index) => {
|
|
2440
2430
|
if (LOWER_CASE_WHEN_NOT_FIRST.includes(word.toLowerCase()) && index > 0) {
|
|
@@ -2445,7 +2435,7 @@ function titleCase(input) {
|
|
|
2445
2435
|
}
|
|
2446
2436
|
return `${word ? word.charAt(0).toUpperCase() + word.toLowerCase().slice(1) : word}`;
|
|
2447
2437
|
}).join(" ");
|
|
2448
|
-
return
|
|
2438
|
+
return input2.split(/\s+-\s+/).map((part) => formatSegment(part)).join(" - ");
|
|
2449
2439
|
}
|
|
2450
2440
|
|
|
2451
2441
|
// src/utilities/changelog-utils.ts
|
|
@@ -2455,7 +2445,7 @@ async function generateChangelogContent(releaseVersion, filepath, newContent, cu
|
|
|
2455
2445
|
const header = await prettier.format(
|
|
2456
2446
|
` : void 0 : workspaceConfig?.release.banner.alt) || "Branded release banner image"}](${bannerUrl || chunkTOLGVHZM_cjs.STORM_DEFAULT_RELEASE_BANNER})
|
|
2459
2449
|
|
|
2460
2450
|
# Changelog ${project || workspaceConfig?.name ? "for" : ""}${workspaceConfig?.name ? ` ${titleCase(workspaceConfig.name)}` : ""}${project ? `${workspaceConfig?.name ? " -" : ""} ${titleCase(project)}` : ""}
|
|
2461
2451
|
|
|
@@ -2631,12 +2621,12 @@ async function generateChangelogForProjects({
|
|
|
2631
2621
|
projectChangelogs
|
|
2632
2622
|
)) {
|
|
2633
2623
|
if (!projectGraph.nodes[projectName]?.data.root) {
|
|
2634
|
-
|
|
2624
|
+
chunkTOLGVHZM_cjs.writeWarning(
|
|
2635
2625
|
`A changelog was generated for ${projectName}, but it could not be found in the project graph. Skipping writing changelog file.`,
|
|
2636
2626
|
workspaceConfig
|
|
2637
2627
|
);
|
|
2638
2628
|
} else if (projectChangelog.contents) {
|
|
2639
|
-
const filePath =
|
|
2629
|
+
const filePath = chunkTOLGVHZM_cjs.joinPaths(
|
|
2640
2630
|
projectGraph.nodes[projectName].data.root,
|
|
2641
2631
|
"CHANGELOG.md"
|
|
2642
2632
|
);
|
|
@@ -2644,7 +2634,7 @@ async function generateChangelogForProjects({
|
|
|
2644
2634
|
if (fs$1.existsSync(filePath)) {
|
|
2645
2635
|
currentContent = await fs.readFile(filePath, "utf8");
|
|
2646
2636
|
}
|
|
2647
|
-
|
|
2637
|
+
chunkTOLGVHZM_cjs.writeDebug(
|
|
2648
2638
|
`\u270D\uFE0F Writing changelog for project ${projectName} to ${filePath}`,
|
|
2649
2639
|
workspaceConfig
|
|
2650
2640
|
);
|
|
@@ -2862,12 +2852,12 @@ async function getLatestGitTagForPattern(workspaceConfig, releaseTagPattern, add
|
|
|
2862
2852
|
if (!matchingTags.length) {
|
|
2863
2853
|
return null;
|
|
2864
2854
|
}
|
|
2865
|
-
|
|
2855
|
+
chunkTOLGVHZM_cjs.writeDebug(
|
|
2866
2856
|
`Found ${matchingTags.length} matching tags out of ${tags.length} total tags for release tag pattern "${releaseTagPattern}" (Interpolated tag pattern: ${interpolatedTagPattern})`,
|
|
2867
2857
|
workspaceConfig
|
|
2868
2858
|
);
|
|
2869
2859
|
if (!strictPreid) {
|
|
2870
|
-
|
|
2860
|
+
chunkTOLGVHZM_cjs.writeTrace(
|
|
2871
2861
|
`Not using strict preid, will use the greatest matching tag of project "${additionalInterpolationData.projectName}"`,
|
|
2872
2862
|
workspaceConfig
|
|
2873
2863
|
);
|
|
@@ -2879,7 +2869,7 @@ async function getLatestGitTagForPattern(workspaceConfig, releaseTagPattern, add
|
|
|
2879
2869
|
const [, version] = matches;
|
|
2880
2870
|
return version && !shared.isPrerelease(version);
|
|
2881
2871
|
});
|
|
2882
|
-
|
|
2872
|
+
chunkTOLGVHZM_cjs.writeDebug(
|
|
2883
2873
|
`Found ${stableReleaseTags.length} stable tags for release tag pattern "${releaseTagPattern}" (Interpolated tag pattern: ${interpolatedTagPattern})`,
|
|
2884
2874
|
workspaceConfig
|
|
2885
2875
|
);
|
|
@@ -2890,7 +2880,7 @@ async function getLatestGitTagForPattern(workspaceConfig, releaseTagPattern, add
|
|
|
2890
2880
|
const version = match.find((part) => part.match(SEMVER_REGEX));
|
|
2891
2881
|
return version && version.includes(`-${preid}.`);
|
|
2892
2882
|
});
|
|
2893
|
-
|
|
2883
|
+
chunkTOLGVHZM_cjs.writeDebug(
|
|
2894
2884
|
`Found ${preidReleaseTags.length} preid tags for release tag pattern "${releaseTagPattern}" (Interpolated tag pattern: ${interpolatedTagPattern})`,
|
|
2895
2885
|
workspaceConfig
|
|
2896
2886
|
);
|
|
@@ -2899,12 +2889,12 @@ async function getLatestGitTagForPattern(workspaceConfig, releaseTagPattern, add
|
|
|
2899
2889
|
const stableResult = compareTags(stableReleaseTags, tagRegexp, options);
|
|
2900
2890
|
const preidBaseVersion = semver.coerce(preidResult.extractedVersion)?.version;
|
|
2901
2891
|
const stableVersion = semver.coerce(stableResult.extractedVersion)?.version;
|
|
2902
|
-
|
|
2892
|
+
chunkTOLGVHZM_cjs.writeDebug(
|
|
2903
2893
|
`Extracted preid version: ${preidBaseVersion} and stable version: ${stableVersion} for release tag pattern "${releaseTagPattern}" (Interpolated tag pattern: ${interpolatedTagPattern})`,
|
|
2904
2894
|
workspaceConfig
|
|
2905
2895
|
);
|
|
2906
2896
|
if (preidBaseVersion && stableVersion && semver.gte(stableVersion, preidBaseVersion)) {
|
|
2907
|
-
|
|
2897
|
+
chunkTOLGVHZM_cjs.writeDebug(
|
|
2908
2898
|
`Using latest stable tag for release tag pattern "${releaseTagPattern}" (Interpolated tag pattern: ${interpolatedTagPattern}) because its version (${stableVersion}) is greater than or equal to the base version of the latest preid tag (${preidBaseVersion})`,
|
|
2909
2899
|
workspaceConfig
|
|
2910
2900
|
);
|
|
@@ -2913,7 +2903,7 @@ async function getLatestGitTagForPattern(workspaceConfig, releaseTagPattern, add
|
|
|
2913
2903
|
return preidResult;
|
|
2914
2904
|
}
|
|
2915
2905
|
if (preidReleaseTags.length > 0) {
|
|
2916
|
-
|
|
2906
|
+
chunkTOLGVHZM_cjs.writeDebug(
|
|
2917
2907
|
`Using latest preid tag for release tag pattern "${releaseTagPattern}" (Interpolated tag pattern: ${interpolatedTagPattern})`,
|
|
2918
2908
|
workspaceConfig
|
|
2919
2909
|
);
|
|
@@ -2921,7 +2911,7 @@ async function getLatestGitTagForPattern(workspaceConfig, releaseTagPattern, add
|
|
|
2921
2911
|
}
|
|
2922
2912
|
}
|
|
2923
2913
|
if (stableReleaseTags.length > 0) {
|
|
2924
|
-
|
|
2914
|
+
chunkTOLGVHZM_cjs.writeDebug(
|
|
2925
2915
|
`Using latest stable tag for release tag pattern "${releaseTagPattern}" (Interpolated tag pattern: ${interpolatedTagPattern})`,
|
|
2926
2916
|
workspaceConfig
|
|
2927
2917
|
);
|
|
@@ -2975,7 +2965,7 @@ var StormGithubRemoteReleaseClient = class extends github.GithubRemoteReleaseCli
|
|
|
2975
2965
|
}
|
|
2976
2966
|
async createOrUpdateRelease(releaseVersion, changelogContents, latestCommit, { dryRun }) {
|
|
2977
2967
|
if (!this.workspaceConfig) {
|
|
2978
|
-
this.workspaceConfig = await
|
|
2968
|
+
this.workspaceConfig = await chunkTOLGVHZM_cjs.getWorkspaceConfig();
|
|
2979
2969
|
}
|
|
2980
2970
|
const name = releaseVersion.gitTag.includes("@") ? releaseVersion.gitTag.replace(new RegExp(`^@${this.workspaceConfig.name}/`), "").replace(/@.*$/, "") : releaseVersion.gitTag;
|
|
2981
2971
|
return super.createOrUpdateRelease(
|
|
@@ -3168,7 +3158,7 @@ async function format3(path, data) {
|
|
|
3168
3158
|
if (resolvedConfig) {
|
|
3169
3159
|
code = await prettier.format(
|
|
3170
3160
|
data,
|
|
3171
|
-
|
|
3161
|
+
defu3.defu(
|
|
3172
3162
|
{
|
|
3173
3163
|
absolutePath: path,
|
|
3174
3164
|
...resolvedConfig
|
|
@@ -3224,7 +3214,7 @@ var StormChangelogRenderer = class extends DefaultChangelogRenderer__default.def
|
|
|
3224
3214
|
}
|
|
3225
3215
|
async render() {
|
|
3226
3216
|
if (!this.workspaceConfig) {
|
|
3227
|
-
this.workspaceConfig = await
|
|
3217
|
+
this.workspaceConfig = await chunkTOLGVHZM_cjs.getWorkspaceConfig();
|
|
3228
3218
|
}
|
|
3229
3219
|
return super.render();
|
|
3230
3220
|
}
|
|
@@ -3531,7 +3521,7 @@ var DEFAULT_RUST_RELEASE_GROUP_CONFIG = {
|
|
|
3531
3521
|
var DEFAULT_RELEASE_CONFIG = {
|
|
3532
3522
|
conventionalCommits: DEFAULT_CONVENTIONAL_COMMITS_CONFIG2,
|
|
3533
3523
|
groups: {
|
|
3534
|
-
packages:
|
|
3524
|
+
packages: defu3__default.default(
|
|
3535
3525
|
{
|
|
3536
3526
|
projects: ["packages/*"]
|
|
3537
3527
|
},
|
|
@@ -3539,7 +3529,7 @@ var DEFAULT_RELEASE_CONFIG = {
|
|
|
3539
3529
|
DEFAULT_INDEPENDENT_RELEASE_GROUP_CONFIG,
|
|
3540
3530
|
DEFAULT_RELEASE_GROUP_CONFIG
|
|
3541
3531
|
),
|
|
3542
|
-
crates:
|
|
3532
|
+
crates: defu3__default.default(
|
|
3543
3533
|
{
|
|
3544
3534
|
projects: ["crates/*"]
|
|
3545
3535
|
},
|
|
@@ -3562,7 +3552,7 @@ var DEFAULT_RELEASE_CONFIG = {
|
|
|
3562
3552
|
}
|
|
3563
3553
|
};
|
|
3564
3554
|
function mergeReleaseGroupConfig(config5, defaultConfig, workspaceConfig) {
|
|
3565
|
-
return
|
|
3555
|
+
return defu3__default.default(
|
|
3566
3556
|
{
|
|
3567
3557
|
...omit(defaultConfig, ["changelog", "version"]),
|
|
3568
3558
|
...config5
|
|
@@ -3593,7 +3583,7 @@ function getReleaseGroupConfig(projectGraph, releaseConfig, workspaceConfig) {
|
|
|
3593
3583
|
projectGraph.nodes
|
|
3594
3584
|
);
|
|
3595
3585
|
if (!matchingProjects.length) {
|
|
3596
|
-
|
|
3586
|
+
chunkTOLGVHZM_cjs.writeWarning(
|
|
3597
3587
|
`Release group "${name}" does not have any matching projects.`
|
|
3598
3588
|
);
|
|
3599
3589
|
return void 0;
|
|
@@ -3613,13 +3603,13 @@ function getReleaseGroupConfig(projectGraph, releaseConfig, workspaceConfig) {
|
|
|
3613
3603
|
ProjectTagConstants.Language.TAG_ID,
|
|
3614
3604
|
ProjectTagConstants.Language.TYPESCRIPT
|
|
3615
3605
|
) || projectGraph.nodes[project]?.data.metadata?.root && fs$1.existsSync(
|
|
3616
|
-
|
|
3606
|
+
chunkTOLGVHZM_cjs.joinPaths(
|
|
3617
3607
|
projectGraph.nodes[project]?.data.metadata?.root,
|
|
3618
3608
|
"package.json"
|
|
3619
3609
|
)
|
|
3620
3610
|
))
|
|
3621
3611
|
)) {
|
|
3622
|
-
defaultConfig =
|
|
3612
|
+
defaultConfig = defu3__default.default(
|
|
3623
3613
|
group.projectsRelationship === "fixed" ? DEFAULT_FIXED_RELEASE_GROUP_CONFIG : DEFAULT_INDEPENDENT_RELEASE_GROUP_CONFIG,
|
|
3624
3614
|
DEFAULT_JS_RELEASE_GROUP_CONFIG,
|
|
3625
3615
|
DEFAULT_RELEASE_GROUP_CONFIG
|
|
@@ -3630,13 +3620,13 @@ function getReleaseGroupConfig(projectGraph, releaseConfig, workspaceConfig) {
|
|
|
3630
3620
|
ProjectTagConstants.Language.TAG_ID,
|
|
3631
3621
|
ProjectTagConstants.Language.RUST
|
|
3632
3622
|
) || projectGraph.nodes[project]?.data.metadata?.root && fs$1.existsSync(
|
|
3633
|
-
|
|
3623
|
+
chunkTOLGVHZM_cjs.joinPaths(
|
|
3634
3624
|
projectGraph.nodes[project]?.data.metadata?.root,
|
|
3635
3625
|
"Cargo.toml"
|
|
3636
3626
|
)
|
|
3637
3627
|
))
|
|
3638
3628
|
)) {
|
|
3639
|
-
defaultConfig =
|
|
3629
|
+
defaultConfig = defu3__default.default(
|
|
3640
3630
|
group.projectsRelationship === "fixed" ? DEFAULT_FIXED_RELEASE_GROUP_CONFIG : DEFAULT_INDEPENDENT_RELEASE_GROUP_CONFIG,
|
|
3641
3631
|
DEFAULT_RUST_RELEASE_GROUP_CONFIG,
|
|
3642
3632
|
DEFAULT_RELEASE_GROUP_CONFIG
|
|
@@ -3650,13 +3640,13 @@ function getReleaseGroupConfig(projectGraph, releaseConfig, workspaceConfig) {
|
|
|
3650
3640
|
config5.projects = matchingProjects;
|
|
3651
3641
|
if (workspaceConfig?.workspaceRoot) {
|
|
3652
3642
|
if (config5.changelog?.renderer && typeof config5.changelog?.renderer === "string" && config5.changelog?.renderer?.toString().startsWith("./")) {
|
|
3653
|
-
config5.changelog.renderer =
|
|
3643
|
+
config5.changelog.renderer = chunkTOLGVHZM_cjs.joinPaths(
|
|
3654
3644
|
workspaceConfig.workspaceRoot,
|
|
3655
3645
|
config5.changelog.renderer
|
|
3656
3646
|
);
|
|
3657
3647
|
}
|
|
3658
3648
|
if (config5.version?.versionActions && config5.version.versionActions.startsWith("./")) {
|
|
3659
|
-
config5.version.versionActions =
|
|
3649
|
+
config5.version.versionActions = chunkTOLGVHZM_cjs.joinPaths(
|
|
3660
3650
|
workspaceConfig.workspaceRoot,
|
|
3661
3651
|
config5.version?.versionActions
|
|
3662
3652
|
);
|
|
@@ -3668,10 +3658,10 @@ function getReleaseGroupConfig(projectGraph, releaseConfig, workspaceConfig) {
|
|
|
3668
3658
|
}
|
|
3669
3659
|
function getReleaseConfig(projectGraph, releaseConfig, workspaceConfig, ignoreNxJsonConfig = false) {
|
|
3670
3660
|
let nxJson$1 = {};
|
|
3671
|
-
if (!ignoreNxJsonConfig && fs$1.existsSync(
|
|
3661
|
+
if (!ignoreNxJsonConfig && fs$1.existsSync(chunkTOLGVHZM_cjs.joinPaths(workspaceConfig.workspaceRoot, "nx.json"))) {
|
|
3672
3662
|
nxJson$1 = nxJson.readNxJson();
|
|
3673
3663
|
}
|
|
3674
|
-
const baseConfig =
|
|
3664
|
+
const baseConfig = defu3__default.default(
|
|
3675
3665
|
{
|
|
3676
3666
|
changelog: {
|
|
3677
3667
|
renderOptions: {
|
|
@@ -3688,7 +3678,7 @@ function getReleaseConfig(projectGraph, releaseConfig, workspaceConfig, ignoreNx
|
|
|
3688
3678
|
if (releaseConfig?.groups && Object.keys(releaseConfig.groups).length > 0) {
|
|
3689
3679
|
groups = releaseConfig.groups;
|
|
3690
3680
|
if (nxJson$1.release?.groups && Object.keys(nxJson$1.release.groups).length > 0) {
|
|
3691
|
-
groups =
|
|
3681
|
+
groups = defu3__default.default(
|
|
3692
3682
|
groups,
|
|
3693
3683
|
nxJson$1.release.groups
|
|
3694
3684
|
);
|
|
@@ -3708,7 +3698,7 @@ function getReleaseConfig(projectGraph, releaseConfig, workspaceConfig, ignoreNx
|
|
|
3708
3698
|
};
|
|
3709
3699
|
}
|
|
3710
3700
|
function formatConfigLog(config5) {
|
|
3711
|
-
return
|
|
3701
|
+
return chunkTOLGVHZM_cjs.formatLogMessage(config5, {
|
|
3712
3702
|
sort: true,
|
|
3713
3703
|
skip: ["workspaceConfig", "conventionalCommits"]
|
|
3714
3704
|
});
|
|
@@ -4121,7 +4111,7 @@ var ReleaseGraph = class _ReleaseGraph {
|
|
|
4121
4111
|
this.resolveRepositoryTags.bind(this),
|
|
4122
4112
|
options
|
|
4123
4113
|
);
|
|
4124
|
-
|
|
4114
|
+
chunkTOLGVHZM_cjs.writeDebug(
|
|
4125
4115
|
`Group release tag pattern: ${releaseTagPattern}
|
|
4126
4116
|
Project release tag pattern: ${projectReleaseTagPattern}
|
|
4127
4117
|
Group release tag: ${groupReleaseTag?.tag}
|
|
@@ -4145,7 +4135,7 @@ Project release tag: ${projectReleaseTag?.tag}`,
|
|
|
4145
4135
|
options
|
|
4146
4136
|
);
|
|
4147
4137
|
}
|
|
4148
|
-
|
|
4138
|
+
chunkTOLGVHZM_cjs.writeInfo(
|
|
4149
4139
|
`Resolved latest matching git tag for "${projectName}": ${latestMatchingGitTag?.tag} (version: ${latestMatchingGitTag?.extractedVersion})`,
|
|
4150
4140
|
this.workspaceConfig
|
|
4151
4141
|
);
|
|
@@ -4415,7 +4405,7 @@ var StormReleaseGroupProcessor = class _StormReleaseGroupProcessor extends relea
|
|
|
4415
4405
|
constructor(tree, workspaceConfig, projectGraph, nxReleaseConfig, releaseGraph, versionOptions) {
|
|
4416
4406
|
super(tree, projectGraph, nxReleaseConfig, releaseGraph, {
|
|
4417
4407
|
dryRun: !!versionOptions.dryRun,
|
|
4418
|
-
verbose: versionOptions.verbose ||
|
|
4408
|
+
verbose: versionOptions.verbose || chunkTOLGVHZM_cjs.isVerbose(workspaceConfig.logLevel),
|
|
4419
4409
|
firstRelease: !!versionOptions.firstRelease,
|
|
4420
4410
|
preid: versionOptions.preid ?? workspaceConfig.preid ?? "",
|
|
4421
4411
|
userGivenSpecifier: versionOptions.specifier,
|
|
@@ -4513,7 +4503,7 @@ var StormReleaseGroupProcessor = class _StormReleaseGroupProcessor extends relea
|
|
|
4513
4503
|
deletedFiles: deletedFilesForVersionActions
|
|
4514
4504
|
} = await afterAllProjectsVersioned(this.#tree.root, {
|
|
4515
4505
|
dryRun: this.versionOptions.dryRun,
|
|
4516
|
-
verbose: this.versionOptions.verbose ||
|
|
4506
|
+
verbose: this.versionOptions.verbose || chunkTOLGVHZM_cjs.isVerbose(this.workspaceConfig.logLevel),
|
|
4517
4507
|
rootVersionActionsOptions
|
|
4518
4508
|
});
|
|
4519
4509
|
for (const file of changedFilesForVersionActions) {
|
|
@@ -4546,7 +4536,7 @@ var StormReleaseGroupProcessor = class _StormReleaseGroupProcessor extends relea
|
|
|
4546
4536
|
let handleDockerVersion;
|
|
4547
4537
|
try {
|
|
4548
4538
|
const dockerVersionUtilsPath = "@nx/docker/release/version-utils";
|
|
4549
|
-
const { handleDockerVersion: _handleDockerVersion } =
|
|
4539
|
+
const { handleDockerVersion: _handleDockerVersion } = chunkTOLGVHZM_cjs.__require(dockerVersionUtilsPath);
|
|
4550
4540
|
handleDockerVersion = _handleDockerVersion;
|
|
4551
4541
|
} catch (e) {
|
|
4552
4542
|
console.error(
|
|
@@ -4634,12 +4624,12 @@ var StormReleaseGroupProcessor = class _StormReleaseGroupProcessor extends relea
|
|
|
4634
4624
|
for (const project of releaseGroup.projects) {
|
|
4635
4625
|
const currentVersion = this.#getCurrentCachedVersionForProject(project);
|
|
4636
4626
|
if (!currentVersion) {
|
|
4637
|
-
|
|
4627
|
+
chunkTOLGVHZM_cjs.writeTrace(
|
|
4638
4628
|
`No current version found for project ${project} in release group ${releaseGroup.name}, skipping version comparison.`,
|
|
4639
4629
|
this.workspaceConfig
|
|
4640
4630
|
);
|
|
4641
4631
|
} else {
|
|
4642
|
-
|
|
4632
|
+
chunkTOLGVHZM_cjs.writeDebug(
|
|
4643
4633
|
`Comparing versions for fixed group ${releaseGroup.name}: Current Greatest Version: ${fixedGroup.currentVersion || "none"}, Current Project Version: ${currentVersion} (project: ${project})`,
|
|
4644
4634
|
this.workspaceConfig
|
|
4645
4635
|
);
|
|
@@ -4665,7 +4655,7 @@ var StormReleaseGroupProcessor = class _StormReleaseGroupProcessor extends relea
|
|
|
4665
4655
|
reasonData: newVersionInputReasonData
|
|
4666
4656
|
};
|
|
4667
4657
|
}
|
|
4668
|
-
|
|
4658
|
+
chunkTOLGVHZM_cjs.writeDebug(
|
|
4669
4659
|
`Fixed release group ${releaseGroup.name} updated: Current Version: ${fixedGroup.currentVersion || "none"}, New Version: ${fixedGroup.newVersion?.input || "none"} (first project: ${project})`,
|
|
4670
4660
|
this.workspaceConfig
|
|
4671
4661
|
);
|
|
@@ -5118,7 +5108,7 @@ var StormReleaseGroupProcessor = class _StormReleaseGroupProcessor extends relea
|
|
|
5118
5108
|
var StormReleaseClient = class _StormReleaseClient extends release.ReleaseClient {
|
|
5119
5109
|
static async create(releaseConfig = {}, ignoreNxJsonConfig = false, workspaceConfig) {
|
|
5120
5110
|
if (!workspaceConfig) {
|
|
5121
|
-
workspaceConfig = await
|
|
5111
|
+
workspaceConfig = await chunkTOLGVHZM_cjs.getWorkspaceConfig();
|
|
5122
5112
|
}
|
|
5123
5113
|
const projectGraph = await devkit.createProjectGraphAsync({
|
|
5124
5114
|
exitOnError: true,
|
|
@@ -5129,7 +5119,7 @@ var StormReleaseClient = class _StormReleaseClient extends release.ReleaseClient
|
|
|
5129
5119
|
"Failed to load the project graph. Please run `nx reset`, then run the `storm-git commit` command again."
|
|
5130
5120
|
);
|
|
5131
5121
|
}
|
|
5132
|
-
|
|
5122
|
+
chunkTOLGVHZM_cjs.writeTrace(
|
|
5133
5123
|
`Provided release configuration:
|
|
5134
5124
|
${formatConfigLog(releaseConfig)}`,
|
|
5135
5125
|
workspaceConfig
|
|
@@ -5140,7 +5130,7 @@ ${formatConfigLog(releaseConfig)}`,
|
|
|
5140
5130
|
workspaceConfig,
|
|
5141
5131
|
ignoreNxJsonConfig
|
|
5142
5132
|
);
|
|
5143
|
-
|
|
5133
|
+
chunkTOLGVHZM_cjs.writeDebug(
|
|
5144
5134
|
`Resolved release configuration:
|
|
5145
5135
|
${formatConfigLog(config5)}`,
|
|
5146
5136
|
workspaceConfig
|
|
@@ -5177,11 +5167,11 @@ ${formatConfigLog(config5)}`,
|
|
|
5177
5167
|
*/
|
|
5178
5168
|
constructor(projectGraph, releaseConfig, workspaceConfig) {
|
|
5179
5169
|
super(releaseConfig, true);
|
|
5180
|
-
|
|
5170
|
+
chunkTOLGVHZM_cjs.writeDebug(
|
|
5181
5171
|
"Executing release with the following configuration",
|
|
5182
5172
|
workspaceConfig
|
|
5183
5173
|
);
|
|
5184
|
-
|
|
5174
|
+
chunkTOLGVHZM_cjs.writeDebug(releaseConfig, workspaceConfig);
|
|
5185
5175
|
this.projectGraph = projectGraph;
|
|
5186
5176
|
this.releaseConfig = releaseConfig;
|
|
5187
5177
|
this.workspaceConfig = workspaceConfig;
|
|
@@ -5209,7 +5199,7 @@ ${formatConfigLog(config5)}`,
|
|
|
5209
5199
|
groups: options.groups
|
|
5210
5200
|
},
|
|
5211
5201
|
firstRelease: !!options.firstRelease,
|
|
5212
|
-
verbose:
|
|
5202
|
+
verbose: chunkTOLGVHZM_cjs.isVerbose(this.workspaceConfig.logLevel)
|
|
5213
5203
|
},
|
|
5214
5204
|
this.workspaceConfig
|
|
5215
5205
|
);
|
|
@@ -5339,7 +5329,7 @@ ${formatConfigLog(config5)}`,
|
|
|
5339
5329
|
})),
|
|
5340
5330
|
this.releaseConfig.conventionalCommits
|
|
5341
5331
|
);
|
|
5342
|
-
|
|
5332
|
+
chunkTOLGVHZM_cjs.writeDebug(
|
|
5343
5333
|
`Running changelog generation for the ${releaseGroup.name} release group`,
|
|
5344
5334
|
this.workspaceConfig
|
|
5345
5335
|
);
|
|
@@ -5414,7 +5404,7 @@ ${formatConfigLog(config5)}`,
|
|
|
5414
5404
|
})),
|
|
5415
5405
|
this.releaseConfig.conventionalCommits
|
|
5416
5406
|
);
|
|
5417
|
-
|
|
5407
|
+
chunkTOLGVHZM_cjs.writeDebug(
|
|
5418
5408
|
`Running changelog generation for the ${releaseGroup.name} release group`,
|
|
5419
5409
|
this.workspaceConfig
|
|
5420
5410
|
);
|
|
@@ -5443,7 +5433,7 @@ ${formatConfigLog(config5)}`,
|
|
|
5443
5433
|
}
|
|
5444
5434
|
}
|
|
5445
5435
|
}
|
|
5446
|
-
|
|
5436
|
+
chunkTOLGVHZM_cjs.writeDebug(
|
|
5447
5437
|
`Generated changelogs for ${Object.keys(allProjectChangelogs).length} projects:
|
|
5448
5438
|
${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
5449
5439
|
`,
|
|
@@ -5472,7 +5462,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5472
5462
|
);
|
|
5473
5463
|
const changes = this.tree.listChanges();
|
|
5474
5464
|
if (!changes.length) {
|
|
5475
|
-
|
|
5465
|
+
chunkTOLGVHZM_cjs.writeWarning(
|
|
5476
5466
|
"No changes were detected for any changelog files, so no changelog entries will be generated.",
|
|
5477
5467
|
this.workspaceConfig
|
|
5478
5468
|
);
|
|
@@ -5494,7 +5484,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5494
5484
|
gitCommitArgs: options.gitCommitArgs || this.releaseConfig.changelog?.git?.commitArgs
|
|
5495
5485
|
});
|
|
5496
5486
|
latestCommit = await git.getCommitHash("HEAD");
|
|
5497
|
-
|
|
5487
|
+
chunkTOLGVHZM_cjs.writeDebug(
|
|
5498
5488
|
`Creating git tags: ${gitTagValues.join(", ")}`,
|
|
5499
5489
|
this.workspaceConfig
|
|
5500
5490
|
);
|
|
@@ -5507,7 +5497,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5507
5497
|
verbose: options.verbose
|
|
5508
5498
|
});
|
|
5509
5499
|
}
|
|
5510
|
-
|
|
5500
|
+
chunkTOLGVHZM_cjs.writeDebug(
|
|
5511
5501
|
`Pushing to git remote "${options.gitRemote ?? "origin"}"`,
|
|
5512
5502
|
this.workspaceConfig
|
|
5513
5503
|
);
|
|
@@ -5523,7 +5513,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5523
5513
|
return;
|
|
5524
5514
|
};
|
|
5525
5515
|
releaseVersion = async (options) => {
|
|
5526
|
-
const verbose = options.verbose ||
|
|
5516
|
+
const verbose = options.verbose || chunkTOLGVHZM_cjs.isVerbose(this.workspaceConfig.logLevel);
|
|
5527
5517
|
this.projectGraph = await devkit.createProjectGraphAsync({
|
|
5528
5518
|
exitOnError: true,
|
|
5529
5519
|
resetDaemonClient: true
|
|
@@ -5550,7 +5540,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5550
5540
|
this.workspaceConfig
|
|
5551
5541
|
);
|
|
5552
5542
|
if (releaseGraph.filterLog && process.env.NX_RELEASE_INTERNAL_SUPPRESS_FILTER_LOG !== "true") {
|
|
5553
|
-
|
|
5543
|
+
chunkTOLGVHZM_cjs.writeDebug(formatNxLog(releaseGraph.filterLog), this.workspaceConfig);
|
|
5554
5544
|
}
|
|
5555
5545
|
if (!options.specifier) {
|
|
5556
5546
|
const rawVersionPlans = await versionPlans.readRawVersionPlans();
|
|
@@ -5569,7 +5559,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5569
5559
|
}
|
|
5570
5560
|
} else {
|
|
5571
5561
|
if (verbose && releaseGraph.releaseGroups.some((g) => !!g.versionPlans)) {
|
|
5572
|
-
|
|
5562
|
+
chunkTOLGVHZM_cjs.writeDebug(
|
|
5573
5563
|
`Skipping version plan discovery as a specifier was provided`,
|
|
5574
5564
|
this.workspaceConfig
|
|
5575
5565
|
);
|
|
@@ -5579,7 +5569,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5579
5569
|
options.deleteVersionPlans = false;
|
|
5580
5570
|
}
|
|
5581
5571
|
if (this.releaseConfig.version?.preVersionCommand) {
|
|
5582
|
-
|
|
5572
|
+
chunkTOLGVHZM_cjs.writeDebug(
|
|
5583
5573
|
"Executing the following pre-version command: \n" + this.releaseConfig.version.preVersionCommand,
|
|
5584
5574
|
this.workspaceConfig
|
|
5585
5575
|
);
|
|
@@ -5615,7 +5605,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5615
5605
|
continue;
|
|
5616
5606
|
}
|
|
5617
5607
|
if (releaseGroup.version?.groupPreVersionCommand) {
|
|
5618
|
-
|
|
5608
|
+
chunkTOLGVHZM_cjs.writeDebug(
|
|
5619
5609
|
`Executing the ${releaseGroup.name} release group's pre-version command:
|
|
5620
5610
|
` + releaseGroup.version?.groupPreVersionCommand,
|
|
5621
5611
|
this.workspaceConfig
|
|
@@ -5675,7 +5665,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5675
5665
|
changed.forEach((f) => additionalChangedFiles.add(f));
|
|
5676
5666
|
deleted.forEach((f) => additionalDeletedFiles.add(f));
|
|
5677
5667
|
if (this.releaseConfig.docker && typeof this.releaseConfig.docker === "object" && this.releaseConfig.docker?.preVersionCommand) {
|
|
5678
|
-
|
|
5668
|
+
chunkTOLGVHZM_cjs.writeDebug(
|
|
5679
5669
|
`Executing the docker pre-version command:
|
|
5680
5670
|
` + this.releaseConfig.docker.preVersionCommand,
|
|
5681
5671
|
this.workspaceConfig
|
|
@@ -5712,7 +5702,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5712
5702
|
continue;
|
|
5713
5703
|
}
|
|
5714
5704
|
if (releaseGroup.docker?.groupPreVersionCommand) {
|
|
5715
|
-
|
|
5705
|
+
chunkTOLGVHZM_cjs.writeDebug(
|
|
5716
5706
|
`Executing the ${releaseGroup.name} release group's docker pre-version command:
|
|
5717
5707
|
` + releaseGroup.docker?.groupPreVersionCommand,
|
|
5718
5708
|
this.workspaceConfig
|
|
@@ -5743,7 +5733,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5743
5733
|
}
|
|
5744
5734
|
}
|
|
5745
5735
|
if (this.releaseConfig.docker || releaseGraph.releaseGroups.some((rg) => rg.docker)) {
|
|
5746
|
-
|
|
5736
|
+
chunkTOLGVHZM_cjs.writeWarning(
|
|
5747
5737
|
formatNxLog({
|
|
5748
5738
|
title: "Warning",
|
|
5749
5739
|
bodyLines: [
|
|
@@ -5800,7 +5790,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5800
5790
|
gitCommitArgs: options.gitCommitArgs || this.releaseConfig.version?.git?.commitArgs
|
|
5801
5791
|
});
|
|
5802
5792
|
} else if (options.stageChanges ?? this.releaseConfig.version?.git?.stageChanges) {
|
|
5803
|
-
|
|
5793
|
+
chunkTOLGVHZM_cjs.writeDebug(`Staging changed files with git`);
|
|
5804
5794
|
await git.gitAdd({
|
|
5805
5795
|
changedFiles,
|
|
5806
5796
|
deletedFiles,
|
|
@@ -5809,7 +5799,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5809
5799
|
});
|
|
5810
5800
|
}
|
|
5811
5801
|
if (options.gitTag ?? this.releaseConfig.version?.git?.tag) {
|
|
5812
|
-
|
|
5802
|
+
chunkTOLGVHZM_cjs.writeDebug(`Tagging commit with git`);
|
|
5813
5803
|
for (const tag of gitTagValues) {
|
|
5814
5804
|
await gitTag({
|
|
5815
5805
|
tag,
|
|
@@ -5821,7 +5811,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5821
5811
|
}
|
|
5822
5812
|
}
|
|
5823
5813
|
if (options.gitPush ?? this.releaseConfig.version?.git?.push) {
|
|
5824
|
-
|
|
5814
|
+
chunkTOLGVHZM_cjs.writeDebug(`Pushing to git remote "${options.gitRemote ?? "origin"}"`);
|
|
5825
5815
|
await git.gitPush({
|
|
5826
5816
|
gitRemote: options.gitRemote,
|
|
5827
5817
|
dryRun: options.dryRun,
|
|
@@ -5852,7 +5842,7 @@ var runRelease = async (config5, {
|
|
|
5852
5842
|
throw new Error("The `GITHUB_ACTOR` environment variable is not set.");
|
|
5853
5843
|
}
|
|
5854
5844
|
if (!await isUserAnOrganizationMember(process.env.GITHUB_ACTOR, config5)) {
|
|
5855
|
-
|
|
5845
|
+
chunkTOLGVHZM_cjs.writeFatal(
|
|
5856
5846
|
"You must be a member of the Storm Software organization to run the release process.",
|
|
5857
5847
|
config5
|
|
5858
5848
|
);
|
|
@@ -5869,23 +5859,23 @@ var runRelease = async (config5, {
|
|
|
5869
5859
|
process.env.NODE_AUTH_TOKEN = process.env.NPM_TOKEN;
|
|
5870
5860
|
process.env.NPM_AUTH_TOKEN = process.env.NPM_TOKEN;
|
|
5871
5861
|
process.env.NPM_CONFIG_PROVENANCE = "true";
|
|
5872
|
-
|
|
5862
|
+
chunkTOLGVHZM_cjs.writeDebug("Creating Storm release client...", config5);
|
|
5873
5863
|
const releaseClient = await StormReleaseClient.create(
|
|
5874
5864
|
releaseConfig,
|
|
5875
5865
|
ignoreNxJsonConfig,
|
|
5876
5866
|
config5
|
|
5877
5867
|
);
|
|
5878
|
-
|
|
5868
|
+
chunkTOLGVHZM_cjs.writeDebug("Reading in the workspaces release configuration", config5);
|
|
5879
5869
|
const to = head || process.env.NX_HEAD;
|
|
5880
5870
|
const from = base || process.env.NX_BASE;
|
|
5881
|
-
|
|
5871
|
+
chunkTOLGVHZM_cjs.writeDebug(
|
|
5882
5872
|
`Using the following Git SHAs to determine the release content:
|
|
5883
5873
|
- From: ${from}
|
|
5884
5874
|
- To: ${to}
|
|
5885
5875
|
`,
|
|
5886
5876
|
config5
|
|
5887
5877
|
);
|
|
5888
|
-
|
|
5878
|
+
chunkTOLGVHZM_cjs.writeDebug("Determining the current release versions...", config5);
|
|
5889
5879
|
const { workspaceVersion, projectsVersionData, releaseGraph } = await releaseClient.releaseVersion({
|
|
5890
5880
|
dryRun,
|
|
5891
5881
|
verbose: true,
|
|
@@ -5902,9 +5892,9 @@ var runRelease = async (config5, {
|
|
|
5902
5892
|
from,
|
|
5903
5893
|
releaseGraph
|
|
5904
5894
|
});
|
|
5905
|
-
|
|
5895
|
+
chunkTOLGVHZM_cjs.writeDebug("Tagging commit with git", config5);
|
|
5906
5896
|
if (skipPublish) {
|
|
5907
|
-
|
|
5897
|
+
chunkTOLGVHZM_cjs.writeWarning(
|
|
5908
5898
|
"Skipping publishing packages since `skipPublish` was provided as `true` in the release options.",
|
|
5909
5899
|
config5
|
|
5910
5900
|
);
|
|
@@ -5913,7 +5903,7 @@ var runRelease = async (config5, {
|
|
|
5913
5903
|
(key) => projectsVersionData[key]?.newVersion
|
|
5914
5904
|
);
|
|
5915
5905
|
if (changedProjects.length > 0) {
|
|
5916
|
-
|
|
5906
|
+
chunkTOLGVHZM_cjs.writeInfo(
|
|
5917
5907
|
`Publishing release for ${changedProjects.length} ${changedProjects.length === 1 ? "project" : "projects"}:
|
|
5918
5908
|
${changedProjects.map((changedProject) => ` - ${changedProject}`).join("\n")}
|
|
5919
5909
|
`,
|
|
@@ -5937,10 +5927,10 @@ ${failedProjects.map((failedProject) => ` - ${failedProject} (Error Code: ${res
|
|
|
5937
5927
|
);
|
|
5938
5928
|
}
|
|
5939
5929
|
} else {
|
|
5940
|
-
|
|
5930
|
+
chunkTOLGVHZM_cjs.writeWarning("Skipped publishing packages.", config5);
|
|
5941
5931
|
}
|
|
5942
5932
|
}
|
|
5943
|
-
|
|
5933
|
+
chunkTOLGVHZM_cjs.writeSuccess("Completed the Storm workspace release process!", config5);
|
|
5944
5934
|
};
|
|
5945
5935
|
async function updatePackageManifests(projectsVersionData, config5) {
|
|
5946
5936
|
let projectGraph;
|
|
@@ -5955,7 +5945,7 @@ async function updatePackageManifests(projectsVersionData, config5) {
|
|
|
5955
5945
|
Object.keys(projectsVersionData).map(async (node) => {
|
|
5956
5946
|
const projectNode = projectGraph.nodes[node];
|
|
5957
5947
|
if (!projectNode?.data.root) {
|
|
5958
|
-
|
|
5948
|
+
chunkTOLGVHZM_cjs.writeWarning(
|
|
5959
5949
|
`Project node ${node} not found in the project graph. Skipping manifest update.`,
|
|
5960
5950
|
config5
|
|
5961
5951
|
);
|
|
@@ -5963,17 +5953,17 @@ async function updatePackageManifests(projectsVersionData, config5) {
|
|
|
5963
5953
|
}
|
|
5964
5954
|
const versionData = projectsVersionData[node];
|
|
5965
5955
|
if (projectNode?.data.root && versionData && versionData.newVersion !== null) {
|
|
5966
|
-
|
|
5956
|
+
chunkTOLGVHZM_cjs.writeTrace(
|
|
5967
5957
|
`Writing version ${versionData.newVersion} update to manifest file for ${node}
|
|
5968
5958
|
`,
|
|
5969
5959
|
config5
|
|
5970
5960
|
);
|
|
5971
|
-
const projectRoot =
|
|
5961
|
+
const projectRoot = chunkTOLGVHZM_cjs.joinPaths(
|
|
5972
5962
|
config5.workspaceRoot,
|
|
5973
5963
|
projectNode.data.root
|
|
5974
5964
|
);
|
|
5975
|
-
const packageJsonPath =
|
|
5976
|
-
const cargoTomlPath =
|
|
5965
|
+
const packageJsonPath = chunkTOLGVHZM_cjs.joinPaths(projectRoot, "package.json");
|
|
5966
|
+
const cargoTomlPath = chunkTOLGVHZM_cjs.joinPaths(projectRoot, "Cargo.toml");
|
|
5977
5967
|
if (fs$1.existsSync(packageJsonPath)) {
|
|
5978
5968
|
const packageJsonContent = await fs.readFile(packageJsonPath, "utf8");
|
|
5979
5969
|
const packageJson = JSON.parse(packageJsonContent);
|
|
@@ -5991,7 +5981,7 @@ async function updatePackageManifests(projectsVersionData, config5) {
|
|
|
5991
5981
|
})
|
|
5992
5982
|
);
|
|
5993
5983
|
} else {
|
|
5994
|
-
|
|
5984
|
+
chunkTOLGVHZM_cjs.writeWarning("No project nodes found. Skipping manifest updates.", config5);
|
|
5995
5985
|
}
|
|
5996
5986
|
}
|
|
5997
5987
|
|
|
@@ -5999,8 +5989,8 @@ async function updatePackageManifests(projectsVersionData, config5) {
|
|
|
5999
5989
|
var _config = {};
|
|
6000
5990
|
function createProgram(config5) {
|
|
6001
5991
|
_config = config5;
|
|
6002
|
-
|
|
6003
|
-
const root =
|
|
5992
|
+
chunkTOLGVHZM_cjs.writeInfo(`${chunkTOLGVHZM_cjs.brandIcon(_config)} Running Storm Git Tools`, config5);
|
|
5993
|
+
const root = chunkTOLGVHZM_cjs.findWorkspaceRootSafe(process.cwd());
|
|
6004
5994
|
process.env.STORM_WORKSPACE_ROOT ??= root;
|
|
6005
5995
|
process.env.NX_WORKSPACE_ROOT_PATH ??= root;
|
|
6006
5996
|
if (root) {
|
|
@@ -6047,12 +6037,12 @@ async function commitAction({
|
|
|
6047
6037
|
dryRun = false
|
|
6048
6038
|
}) {
|
|
6049
6039
|
try {
|
|
6050
|
-
|
|
6051
|
-
`${
|
|
6040
|
+
chunkTOLGVHZM_cjs.writeInfo(
|
|
6041
|
+
`${chunkTOLGVHZM_cjs.brandIcon(typeof config5 === "string" ? {} : config5)} Preparing to commit your changes. Please provide the requested details below...`,
|
|
6052
6042
|
_config
|
|
6053
6043
|
);
|
|
6054
6044
|
await runCommit(config5, dryRun);
|
|
6055
|
-
|
|
6045
|
+
chunkTOLGVHZM_cjs.writeSuccess(
|
|
6056
6046
|
`\u2714 Storm Commit processing completed successfully!
|
|
6057
6047
|
|
|
6058
6048
|
Note: Please run "pnpm push" to upload these changes to the remote ${_config.name ? _config.name : _config.namespace ? _config.namespace : _config.organization ? _config.organization : "Storm-Software"} Git repository at ${_config.repository}
|
|
@@ -6060,7 +6050,7 @@ Note: Please run "pnpm push" to upload these changes to the remote ${_config.nam
|
|
|
6060
6050
|
_config
|
|
6061
6051
|
);
|
|
6062
6052
|
} catch (error) {
|
|
6063
|
-
|
|
6053
|
+
chunkTOLGVHZM_cjs.writeFatal(
|
|
6064
6054
|
`A fatal error occurred while running commit action:
|
|
6065
6055
|
|
|
6066
6056
|
${error.message}${error.stack ? `
|
|
@@ -6075,17 +6065,17 @@ Please fix any errors and try committing again.`,
|
|
|
6075
6065
|
}
|
|
6076
6066
|
async function readmeAction(options) {
|
|
6077
6067
|
try {
|
|
6078
|
-
|
|
6079
|
-
`${
|
|
6068
|
+
chunkTOLGVHZM_cjs.writeInfo(
|
|
6069
|
+
`${chunkTOLGVHZM_cjs.brandIcon(_config)} Formatting the workspace's README.md files`,
|
|
6080
6070
|
_config
|
|
6081
6071
|
);
|
|
6082
6072
|
await runReadme(options);
|
|
6083
|
-
|
|
6073
|
+
chunkTOLGVHZM_cjs.writeSuccess(
|
|
6084
6074
|
"\u2714 Formatting of the workspace's README.md files is complete\n",
|
|
6085
6075
|
_config
|
|
6086
6076
|
);
|
|
6087
6077
|
} catch (error) {
|
|
6088
|
-
|
|
6078
|
+
chunkTOLGVHZM_cjs.writeFatal(
|
|
6089
6079
|
`A fatal error occurred while running README format action:
|
|
6090
6080
|
|
|
6091
6081
|
${error.message}
|
|
@@ -6104,8 +6094,8 @@ async function releaseAction({
|
|
|
6104
6094
|
dryRun
|
|
6105
6095
|
}) {
|
|
6106
6096
|
try {
|
|
6107
|
-
|
|
6108
|
-
`${
|
|
6097
|
+
chunkTOLGVHZM_cjs.writeInfo(
|
|
6098
|
+
`${chunkTOLGVHZM_cjs.brandIcon(_config)} Running the Storm Release and Publish process on the workspace`,
|
|
6109
6099
|
_config
|
|
6110
6100
|
);
|
|
6111
6101
|
await runRelease(_config, {
|
|
@@ -6114,9 +6104,9 @@ async function releaseAction({
|
|
|
6114
6104
|
base,
|
|
6115
6105
|
head
|
|
6116
6106
|
});
|
|
6117
|
-
|
|
6107
|
+
chunkTOLGVHZM_cjs.writeSuccess("\u2714 Release completed successfully!\n", _config);
|
|
6118
6108
|
} catch (error) {
|
|
6119
|
-
|
|
6109
|
+
chunkTOLGVHZM_cjs.writeFatal(
|
|
6120
6110
|
`A fatal error occurred while running release action:
|
|
6121
6111
|
|
|
6122
6112
|
${error.message} ${error.stack ? `
|
|
@@ -6130,17 +6120,17 @@ Stacktrace: ${error.stack}` : ""}`,
|
|
|
6130
6120
|
}
|
|
6131
6121
|
async function commitLintAction(options) {
|
|
6132
6122
|
try {
|
|
6133
|
-
|
|
6134
|
-
`${
|
|
6123
|
+
chunkTOLGVHZM_cjs.writeInfo(
|
|
6124
|
+
`${chunkTOLGVHZM_cjs.brandIcon(_config)} Linting the ${_config.repository ? _config.repository : _config.namespace ? _config.namespace : _config.name ? _config.name : typeof _config.organization === "string" ? _config.organization : _config.organization?.name ? _config.organization?.name : "Storm-Software"} repository's commit messages.`,
|
|
6135
6125
|
_config
|
|
6136
6126
|
);
|
|
6137
6127
|
await runCommitLint(_config, options);
|
|
6138
|
-
|
|
6128
|
+
chunkTOLGVHZM_cjs.writeSuccess(
|
|
6139
6129
|
"\u2714 Linting the commit messages completed successfully!\n",
|
|
6140
6130
|
_config
|
|
6141
6131
|
);
|
|
6142
6132
|
} catch (error) {
|
|
6143
|
-
|
|
6133
|
+
chunkTOLGVHZM_cjs.writeFatal(
|
|
6144
6134
|
`A fatal error occurred while linting the commit messages:
|
|
6145
6135
|
|
|
6146
6136
|
${error.message}`,
|
|
@@ -6151,14 +6141,14 @@ ${error.message}`,
|
|
|
6151
6141
|
}
|
|
6152
6142
|
async function postCheckoutAction({ files }) {
|
|
6153
6143
|
try {
|
|
6154
|
-
|
|
6155
|
-
`${
|
|
6144
|
+
chunkTOLGVHZM_cjs.writeInfo(
|
|
6145
|
+
`${chunkTOLGVHZM_cjs.brandIcon(_config)} Running the Storm post-checkout git hook for ${files.length} files in the workspace...`,
|
|
6156
6146
|
_config
|
|
6157
6147
|
);
|
|
6158
|
-
await
|
|
6159
|
-
|
|
6148
|
+
await chunkIHDSESSE_cjs.postCheckoutHook(_config, files);
|
|
6149
|
+
chunkTOLGVHZM_cjs.writeSuccess("\u2714 Post-checkout hook completed successfully!\n", _config);
|
|
6160
6150
|
} catch (error) {
|
|
6161
|
-
|
|
6151
|
+
chunkTOLGVHZM_cjs.writeFatal(
|
|
6162
6152
|
`A fatal error occurred while running the post-checkout hook:
|
|
6163
6153
|
|
|
6164
6154
|
${error.message}`,
|
|
@@ -6169,14 +6159,14 @@ ${error.message}`,
|
|
|
6169
6159
|
}
|
|
6170
6160
|
async function postCommitAction({ files }) {
|
|
6171
6161
|
try {
|
|
6172
|
-
|
|
6173
|
-
`${
|
|
6162
|
+
chunkTOLGVHZM_cjs.writeInfo(
|
|
6163
|
+
`${chunkTOLGVHZM_cjs.brandIcon(_config)} Running the Storm post-commit git hook for ${files.length} files in the workspace...`,
|
|
6174
6164
|
_config
|
|
6175
6165
|
);
|
|
6176
|
-
await
|
|
6177
|
-
|
|
6166
|
+
await chunkGT7HITVF_cjs.postCommitHook(_config, files);
|
|
6167
|
+
chunkTOLGVHZM_cjs.writeSuccess("\u2714 Post-commit hook completed successfully!\n", _config);
|
|
6178
6168
|
} catch (error) {
|
|
6179
|
-
|
|
6169
|
+
chunkTOLGVHZM_cjs.writeFatal(
|
|
6180
6170
|
`A fatal error occurred while running the post-commit hook:
|
|
6181
6171
|
|
|
6182
6172
|
${error.message}`,
|
|
@@ -6187,14 +6177,14 @@ ${error.message}`,
|
|
|
6187
6177
|
}
|
|
6188
6178
|
async function postMergeAction({ files }) {
|
|
6189
6179
|
try {
|
|
6190
|
-
|
|
6191
|
-
`${
|
|
6180
|
+
chunkTOLGVHZM_cjs.writeInfo(
|
|
6181
|
+
`${chunkTOLGVHZM_cjs.brandIcon(_config)} Running the Storm post-merge git hook for ${files.length} files in the workspace...`,
|
|
6192
6182
|
_config
|
|
6193
6183
|
);
|
|
6194
|
-
await
|
|
6195
|
-
|
|
6184
|
+
await chunkSZFP3TKI_cjs.postMergeHook(_config, files);
|
|
6185
|
+
chunkTOLGVHZM_cjs.writeSuccess("\u2714 Post-merge hook completed successfully!\n", _config);
|
|
6196
6186
|
} catch (error) {
|
|
6197
|
-
|
|
6187
|
+
chunkTOLGVHZM_cjs.writeFatal(
|
|
6198
6188
|
`A fatal error occurred while running the post-merge hook:
|
|
6199
6189
|
|
|
6200
6190
|
${error.message}`,
|
|
@@ -6205,14 +6195,14 @@ ${error.message}`,
|
|
|
6205
6195
|
}
|
|
6206
6196
|
async function preCommitAction({ files }) {
|
|
6207
6197
|
try {
|
|
6208
|
-
|
|
6209
|
-
`${
|
|
6198
|
+
chunkTOLGVHZM_cjs.writeInfo(
|
|
6199
|
+
`${chunkTOLGVHZM_cjs.brandIcon(_config)} Running the Storm pre-commit git hook for ${files.length} files in the workspace...`,
|
|
6210
6200
|
_config
|
|
6211
6201
|
);
|
|
6212
|
-
await
|
|
6213
|
-
|
|
6202
|
+
await chunkZJN2D7NE_cjs.preCommitHook(_config, files);
|
|
6203
|
+
chunkTOLGVHZM_cjs.writeSuccess("\u2714 Pre-commit hook completed successfully!\n", _config);
|
|
6214
6204
|
} catch (error) {
|
|
6215
|
-
|
|
6205
|
+
chunkTOLGVHZM_cjs.writeFatal(
|
|
6216
6206
|
`A fatal error occurred while running the pre-commit hook:
|
|
6217
6207
|
|
|
6218
6208
|
${error.message}`,
|
|
@@ -6223,14 +6213,14 @@ ${error.message}`,
|
|
|
6223
6213
|
}
|
|
6224
6214
|
async function prePushAction({ files }) {
|
|
6225
6215
|
try {
|
|
6226
|
-
|
|
6227
|
-
`${
|
|
6216
|
+
chunkTOLGVHZM_cjs.writeInfo(
|
|
6217
|
+
`${chunkTOLGVHZM_cjs.brandIcon(_config)} Running the Storm pre-push git hook for ${files.length} files in the workspace...`,
|
|
6228
6218
|
_config
|
|
6229
6219
|
);
|
|
6230
|
-
await
|
|
6231
|
-
|
|
6220
|
+
await chunkQBI7KQ6A_cjs.prePushHook(_config, files);
|
|
6221
|
+
chunkTOLGVHZM_cjs.writeSuccess("\u2714 Pre-push hook completed successfully!\n", _config);
|
|
6232
6222
|
} catch (error) {
|
|
6233
|
-
|
|
6223
|
+
chunkTOLGVHZM_cjs.writeFatal(
|
|
6234
6224
|
`A fatal error occurred while running the pre-push hook:
|
|
6235
6225
|
|
|
6236
6226
|
${error.message}`,
|
|
@@ -6241,14 +6231,14 @@ ${error.message}`,
|
|
|
6241
6231
|
}
|
|
6242
6232
|
async function prepareAction() {
|
|
6243
6233
|
try {
|
|
6244
|
-
|
|
6245
|
-
`${
|
|
6234
|
+
chunkTOLGVHZM_cjs.writeInfo(
|
|
6235
|
+
`${chunkTOLGVHZM_cjs.brandIcon(_config)} Running the Storm prepare git hook for the workspace...`,
|
|
6246
6236
|
_config
|
|
6247
6237
|
);
|
|
6248
|
-
await
|
|
6249
|
-
|
|
6238
|
+
await chunkJYYYVLIU_cjs.prepareHook(_config);
|
|
6239
|
+
chunkTOLGVHZM_cjs.writeSuccess("\u2714 Prepare hook completed successfully!\n", _config);
|
|
6250
6240
|
} catch (error) {
|
|
6251
|
-
|
|
6241
|
+
chunkTOLGVHZM_cjs.writeFatal(
|
|
6252
6242
|
`A fatal error occurred while running the prepare hook:
|
|
6253
6243
|
|
|
6254
6244
|
${error.message}`,
|
|
@@ -6260,18 +6250,18 @@ ${error.message}`,
|
|
|
6260
6250
|
|
|
6261
6251
|
// bin/git.ts
|
|
6262
6252
|
void (async () => {
|
|
6263
|
-
const config5 = await
|
|
6253
|
+
const config5 = await chunkTOLGVHZM_cjs.getConfig();
|
|
6264
6254
|
try {
|
|
6265
|
-
|
|
6255
|
+
chunkTOLGVHZM_cjs.handleProcess(config5);
|
|
6266
6256
|
const program = createProgram(config5);
|
|
6267
6257
|
await program.parseAsync(process.argv);
|
|
6268
|
-
|
|
6258
|
+
chunkTOLGVHZM_cjs.writeSuccess(
|
|
6269
6259
|
`\u2714 Git ${process.argv && process.argv.length >= 3 && process.argv[2] ? process.argv[2] : "tool"} processing completed successfully!`,
|
|
6270
6260
|
config5
|
|
6271
6261
|
);
|
|
6272
|
-
|
|
6262
|
+
chunkTOLGVHZM_cjs.exitWithSuccess(config5);
|
|
6273
6263
|
} catch (error) {
|
|
6274
|
-
|
|
6264
|
+
chunkTOLGVHZM_cjs.exitWithError(config5);
|
|
6275
6265
|
process.exit(1);
|
|
6276
6266
|
}
|
|
6277
6267
|
})();
|