@storm-software/git-tools 2.131.28 → 2.131.31
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-AX3PXQKJ.js → chunk-3I7DR63M.js} +3 -3
- package/bin/{chunk-AX3PXQKJ.js.map → chunk-3I7DR63M.js.map} +1 -1
- package/bin/{chunk-C6K3ZRT6.js → chunk-3NC3GIM6.js} +3 -3
- package/bin/{chunk-C6K3ZRT6.js.map → chunk-3NC3GIM6.js.map} +1 -1
- package/bin/{chunk-MQOEMLKV.cjs → chunk-6AN4QYAN.cjs} +4 -4
- package/bin/{chunk-MQOEMLKV.cjs.map → chunk-6AN4QYAN.cjs.map} +1 -1
- package/bin/{chunk-QITSXT5W.cjs → chunk-AY74OKG5.cjs} +6 -6
- package/bin/{chunk-QITSXT5W.cjs.map → chunk-AY74OKG5.cjs.map} +1 -1
- package/bin/{chunk-M4UDDFX2.cjs → chunk-B56KWU7H.cjs} +4 -4
- package/bin/{chunk-M4UDDFX2.cjs.map → chunk-B56KWU7H.cjs.map} +1 -1
- package/bin/{chunk-3XAQUPZK.js → chunk-BPY6SBLC.js} +5 -5
- package/bin/chunk-BPY6SBLC.js.map +1 -0
- package/bin/{chunk-GPHBDU6A.js → chunk-DDC7F5UZ.js} +3 -3
- package/bin/{chunk-GPHBDU6A.js.map → chunk-DDC7F5UZ.js.map} +1 -1
- package/bin/{chunk-Y7OK7243.js → chunk-EQ7Z3P24.js} +3 -3
- package/bin/{chunk-Y7OK7243.js.map → chunk-EQ7Z3P24.js.map} +1 -1
- package/bin/{chunk-4GZZR7XL.js → chunk-FC4WBB3T.js} +3 -3
- package/bin/{chunk-4GZZR7XL.js.map → chunk-FC4WBB3T.js.map} +1 -1
- package/bin/{chunk-QOOEK76B.cjs → chunk-M4LUWNQR.cjs} +5 -5
- package/bin/chunk-M4LUWNQR.cjs.map +1 -0
- package/bin/{chunk-WZZIVUHI.cjs → chunk-O3X5QPCQ.cjs} +4 -4
- package/bin/{chunk-WZZIVUHI.cjs.map → chunk-O3X5QPCQ.cjs.map} +1 -1
- package/bin/{chunk-DOELUOOS.js → chunk-O5U4PY3Z.js} +3 -3
- package/bin/{chunk-DOELUOOS.js.map → chunk-O5U4PY3Z.js.map} +1 -1
- package/bin/{chunk-3PI2VV32.js → chunk-SJQTSJGU.js} +3 -3
- package/bin/{chunk-3PI2VV32.js.map → chunk-SJQTSJGU.js.map} +1 -1
- package/bin/{chunk-3LVCR6LS.cjs → chunk-U7X6DX3D.cjs} +4 -4
- package/bin/{chunk-3LVCR6LS.cjs.map → chunk-U7X6DX3D.cjs.map} +1 -1
- package/bin/{chunk-4CS5RPMP.cjs → chunk-Y7LS5W35.cjs} +5 -5
- package/bin/{chunk-4CS5RPMP.cjs.map → chunk-Y7LS5W35.cjs.map} +1 -1
- package/bin/{chunk-NSP7UDOF.cjs → chunk-ZMVLIEV4.cjs} +4 -4
- package/bin/{chunk-NSP7UDOF.cjs.map → chunk-ZMVLIEV4.cjs.map} +1 -1
- package/bin/git.cjs +177 -224
- package/bin/git.cjs.map +1 -1
- package/bin/git.js +33 -80
- 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/package.json +11 -11
- package/bin/chunk-3XAQUPZK.js.map +0 -1
- package/bin/chunk-QOOEK76B.cjs.map +0 -1
package/bin/git.cjs
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
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 chunkO3X5QPCQ_cjs = require('./chunk-O3X5QPCQ.cjs');
|
|
5
|
+
var chunkZMVLIEV4_cjs = require('./chunk-ZMVLIEV4.cjs');
|
|
6
|
+
var chunkB56KWU7H_cjs = require('./chunk-B56KWU7H.cjs');
|
|
7
|
+
var chunk6AN4QYAN_cjs = require('./chunk-6AN4QYAN.cjs');
|
|
8
|
+
require('./chunk-Y7LS5W35.cjs');
|
|
9
|
+
var chunkAY74OKG5_cjs = require('./chunk-AY74OKG5.cjs');
|
|
10
10
|
require('./chunk-YHZNDNCW.cjs');
|
|
11
|
-
var
|
|
11
|
+
var chunkU7X6DX3D_cjs = require('./chunk-U7X6DX3D.cjs');
|
|
12
12
|
var chunkMTAYUS7E_cjs = require('./chunk-MTAYUS7E.cjs');
|
|
13
|
-
var
|
|
13
|
+
var chunkM4LUWNQR_cjs = require('./chunk-M4LUWNQR.cjs');
|
|
14
14
|
var TOML = require('@ltd/j-toml');
|
|
15
15
|
var commander = require('commander');
|
|
16
16
|
require('@inquirer/checkbox');
|
|
@@ -432,9 +432,9 @@ function getRuleFromScopeEnum(scopeEnum) {
|
|
|
432
432
|
|
|
433
433
|
// ../conventional-changelog/src/index.ts
|
|
434
434
|
async function createPreset(variant = "monorepo") {
|
|
435
|
-
const workspaceConfig = await
|
|
435
|
+
const workspaceConfig = await chunkM4LUWNQR_cjs.getWorkspaceConfig();
|
|
436
436
|
if (variant === "minimal") {
|
|
437
|
-
return
|
|
437
|
+
return chunkM4LUWNQR_cjs.defu(
|
|
438
438
|
await createBasePreset__default.default({ ...COMMIT_CONFIGS.minimal.changelogs.props }),
|
|
439
439
|
{
|
|
440
440
|
...COMMIT_CONFIGS.minimal,
|
|
@@ -448,7 +448,7 @@ async function createPreset(variant = "monorepo") {
|
|
|
448
448
|
);
|
|
449
449
|
}
|
|
450
450
|
const nxScopes = await getNxScopes({ config: workspaceConfig });
|
|
451
|
-
return
|
|
451
|
+
return chunkM4LUWNQR_cjs.defu(
|
|
452
452
|
await createBasePreset__default.default({
|
|
453
453
|
...COMMIT_CONFIGS.monorepo.changelogs.props,
|
|
454
454
|
scope: nxScopes
|
|
@@ -1012,7 +1012,7 @@ async function lint(message, config5) {
|
|
|
1012
1012
|
// src/commitlint/run.ts
|
|
1013
1013
|
var COMMIT_EDITMSG_PATH = ".git/COMMIT_EDITMSG";
|
|
1014
1014
|
async function runCommitLint(workspaceConfig, options) {
|
|
1015
|
-
|
|
1015
|
+
chunkM4LUWNQR_cjs.writeInfo(
|
|
1016
1016
|
"\u{1F4DD} Validating git commit message aligns with the Storm Software specification",
|
|
1017
1017
|
workspaceConfig
|
|
1018
1018
|
);
|
|
@@ -1020,7 +1020,7 @@ async function runCommitLint(workspaceConfig, options) {
|
|
|
1020
1020
|
if (options.message && options.message !== COMMIT_EDITMSG_PATH) {
|
|
1021
1021
|
commitMessage = options.message;
|
|
1022
1022
|
} else {
|
|
1023
|
-
const commitFile =
|
|
1023
|
+
const commitFile = chunkM4LUWNQR_cjs.joinPaths(
|
|
1024
1024
|
workspaceConfig.workspaceRoot,
|
|
1025
1025
|
options.file || options.message || COMMIT_EDITMSG_PATH
|
|
1026
1026
|
);
|
|
@@ -1037,17 +1037,17 @@ async function runCommitLint(workspaceConfig, options) {
|
|
|
1037
1037
|
if (upstreamRemote) {
|
|
1038
1038
|
const upstreamRemoteIdentifier = upstreamRemote.split(" ")[0]?.trim();
|
|
1039
1039
|
if (!upstreamRemoteIdentifier) {
|
|
1040
|
-
|
|
1040
|
+
chunkM4LUWNQR_cjs.writeWarning(
|
|
1041
1041
|
`No upstream remote found for ${workspaceConfig.name}.git. Skipping comparison.`,
|
|
1042
1042
|
workspaceConfig
|
|
1043
1043
|
);
|
|
1044
1044
|
return;
|
|
1045
1045
|
}
|
|
1046
|
-
|
|
1046
|
+
chunkM4LUWNQR_cjs.writeDebug(`Comparing against remote ${upstreamRemoteIdentifier}`);
|
|
1047
1047
|
const currentBranch = childProcess__default.default.execSync("git branch --show-current").toString().trim();
|
|
1048
1048
|
gitLogCmd = gitLogCmd + ` ${currentBranch} ^${upstreamRemoteIdentifier}/main`;
|
|
1049
1049
|
} else {
|
|
1050
|
-
|
|
1050
|
+
chunkM4LUWNQR_cjs.writeWarning(
|
|
1051
1051
|
`No upstream remote found for ${workspaceConfig.name}.git. Skipping comparison against upstream main.`,
|
|
1052
1052
|
workspaceConfig
|
|
1053
1053
|
);
|
|
@@ -1055,7 +1055,7 @@ async function runCommitLint(workspaceConfig, options) {
|
|
|
1055
1055
|
}
|
|
1056
1056
|
commitMessage = childProcess__default.default.execSync(gitLogCmd).toString().trim();
|
|
1057
1057
|
if (!commitMessage) {
|
|
1058
|
-
|
|
1058
|
+
chunkM4LUWNQR_cjs.writeWarning(
|
|
1059
1059
|
"No commits found. Skipping commit message validation.",
|
|
1060
1060
|
workspaceConfig
|
|
1061
1061
|
);
|
|
@@ -1065,7 +1065,7 @@ async function runCommitLint(workspaceConfig, options) {
|
|
|
1065
1065
|
const preset = await createPreset(workspaceConfig.variant);
|
|
1066
1066
|
const report = await lint(commitMessage, preset);
|
|
1067
1067
|
if (!preset.commitlint.regex.test(commitMessage) || report.errors.length || report.warnings.length) {
|
|
1068
|
-
|
|
1068
|
+
chunkM4LUWNQR_cjs.writeSuccess(
|
|
1069
1069
|
`Commit was processing completed successfully!`,
|
|
1070
1070
|
workspaceConfig
|
|
1071
1071
|
);
|
|
@@ -1277,7 +1277,7 @@ async function createState(workspaceConfig, configPath) {
|
|
|
1277
1277
|
const project = projectConfigurations.projects[scope];
|
|
1278
1278
|
if (project) {
|
|
1279
1279
|
let description = `${project.name} - ${project.root}`;
|
|
1280
|
-
const packageJsonPath =
|
|
1280
|
+
const packageJsonPath = chunkM4LUWNQR_cjs.joinPaths(project.root, "package.json");
|
|
1281
1281
|
if (fs$1.existsSync(packageJsonPath)) {
|
|
1282
1282
|
const packageJsonFile = await fs.readFile(packageJsonPath, "utf8");
|
|
1283
1283
|
const packageJson = JSON.parse(packageJsonFile);
|
|
@@ -1351,20 +1351,20 @@ ${closedIssueEmoji}${config5.settings.closedIssueMessage}${issues}`;
|
|
|
1351
1351
|
|
|
1352
1352
|
// src/commit/run.ts
|
|
1353
1353
|
async function runCommit(commitizenFile, dryRun = false) {
|
|
1354
|
-
const workspaceConfig = await
|
|
1354
|
+
const workspaceConfig = await chunkM4LUWNQR_cjs.getWorkspaceConfig();
|
|
1355
1355
|
const state = await createState(workspaceConfig);
|
|
1356
1356
|
if (dryRun) {
|
|
1357
|
-
|
|
1357
|
+
chunkM4LUWNQR_cjs.writeInfo("Running in dry mode.", workspaceConfig);
|
|
1358
1358
|
}
|
|
1359
1359
|
console.log(chalkTemplate__default.default`
|
|
1360
1360
|
{bold.#999999 ----------------------------------------}
|
|
1361
1361
|
|
|
1362
|
-
{bold.#FFFFFF ${
|
|
1362
|
+
{bold.#FFFFFF ${chunkM4LUWNQR_cjs.brandIcon(workspaceConfig)} Storm Software Git-Tools - Commit}
|
|
1363
1363
|
{#CCCCCC Please provide the requested details below...}
|
|
1364
1364
|
`);
|
|
1365
1365
|
state.answers = await askQuestions(state);
|
|
1366
1366
|
const message = formatCommitMessage(state, workspaceConfig);
|
|
1367
|
-
const commitMsgFile =
|
|
1367
|
+
const commitMsgFile = chunkM4LUWNQR_cjs.joinPaths(getGitDir(), "COMMIT_EDITMSG");
|
|
1368
1368
|
console.log(chalkTemplate__default.default`
|
|
1369
1369
|
{bold.#999999 ----------------------------------------}
|
|
1370
1370
|
|
|
@@ -1377,11 +1377,11 @@ async function runCommit(commitizenFile, dryRun = false) {
|
|
|
1377
1377
|
commandItems.push(...["--file", commitMsgFile]);
|
|
1378
1378
|
const command = shellescape__default.default(commandItems);
|
|
1379
1379
|
if (dryRun) {
|
|
1380
|
-
|
|
1380
|
+
chunkM4LUWNQR_cjs.writeDebug(
|
|
1381
1381
|
`Skipping execution [dry-run]: ${command.replace(commitMsgFile, ".git/COMMIT_EDITMSG")}`,
|
|
1382
1382
|
workspaceConfig
|
|
1383
1383
|
);
|
|
1384
|
-
|
|
1384
|
+
chunkM4LUWNQR_cjs.writeDebug(`Message [dry-run]: ${message}`, workspaceConfig);
|
|
1385
1385
|
} else {
|
|
1386
1386
|
await fs__default.default.writeFile(commitMsgFile, message);
|
|
1387
1387
|
chunkMTAYUS7E_cjs.run(workspaceConfig, command);
|
|
@@ -2040,7 +2040,7 @@ var runReadme = async ({
|
|
|
2040
2040
|
exitOnError: true
|
|
2041
2041
|
});
|
|
2042
2042
|
const projectConfigs = projectGraph_js.readProjectsConfigurationFromProjectGraph(projectGraph);
|
|
2043
|
-
const workspaceRoot =
|
|
2043
|
+
const workspaceRoot = chunkM4LUWNQR_cjs.findWorkspaceRootSafe(process.cwd());
|
|
2044
2044
|
if (!workspaceRoot) {
|
|
2045
2045
|
throw new Error(
|
|
2046
2046
|
"Unable to find the workspace root. Please ensure you are running this command from within a workspace."
|
|
@@ -2457,7 +2457,7 @@ async function generateChangelogContent(releaseVersion, filepath, newContent, cu
|
|
|
2457
2457
|
const header = await prettier.format(
|
|
2458
2458
|
` : void 0 : workspaceConfig?.release.banner.alt) || "Branded release banner image"}](${bannerUrl || chunkM4LUWNQR_cjs.STORM_DEFAULT_RELEASE_BANNER})
|
|
2461
2461
|
|
|
2462
2462
|
# Changelog ${project || workspaceConfig?.name ? "for" : ""}${workspaceConfig?.name ? ` ${titleCase(workspaceConfig.name)}` : ""}${project ? `${workspaceConfig?.name ? " -" : ""} ${titleCase(project)}` : ""}
|
|
2463
2463
|
|
|
@@ -2633,12 +2633,12 @@ async function generateChangelogForProjects({
|
|
|
2633
2633
|
projectChangelogs
|
|
2634
2634
|
)) {
|
|
2635
2635
|
if (!projectGraph.nodes[projectName]?.data.root) {
|
|
2636
|
-
|
|
2636
|
+
chunkM4LUWNQR_cjs.writeWarning(
|
|
2637
2637
|
`A changelog was generated for ${projectName}, but it could not be found in the project graph. Skipping writing changelog file.`,
|
|
2638
2638
|
workspaceConfig
|
|
2639
2639
|
);
|
|
2640
2640
|
} else if (projectChangelog.contents) {
|
|
2641
|
-
const filePath =
|
|
2641
|
+
const filePath = chunkM4LUWNQR_cjs.joinPaths(
|
|
2642
2642
|
projectGraph.nodes[projectName].data.root,
|
|
2643
2643
|
"CHANGELOG.md"
|
|
2644
2644
|
);
|
|
@@ -2646,7 +2646,7 @@ async function generateChangelogForProjects({
|
|
|
2646
2646
|
if (fs$1.existsSync(filePath)) {
|
|
2647
2647
|
currentContent = await fs.readFile(filePath, "utf8");
|
|
2648
2648
|
}
|
|
2649
|
-
|
|
2649
|
+
chunkM4LUWNQR_cjs.writeDebug(
|
|
2650
2650
|
`\u270D\uFE0F Writing changelog for project ${projectName} to ${filePath}`,
|
|
2651
2651
|
workspaceConfig
|
|
2652
2652
|
);
|
|
@@ -2673,8 +2673,7 @@ async function generateChangelogForProjects({
|
|
|
2673
2673
|
return projectChangelogs;
|
|
2674
2674
|
}
|
|
2675
2675
|
async function getCommits(fromSHA, toSHA) {
|
|
2676
|
-
|
|
2677
|
-
return git.parseCommits(rawCommits);
|
|
2676
|
+
return git.parseCommits(await git.getGitDiff(fromSHA, toSHA));
|
|
2678
2677
|
}
|
|
2679
2678
|
async function filterProjectCommits({
|
|
2680
2679
|
fromSHA,
|
|
@@ -2827,6 +2826,20 @@ async function commitChanges({
|
|
|
2827
2826
|
});
|
|
2828
2827
|
}
|
|
2829
2828
|
var SEMVER_REGEX = /^(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?$/g;
|
|
2829
|
+
function compareTags(tags, tagRegexp, options) {
|
|
2830
|
+
return tags.reduce(
|
|
2831
|
+
(ret, releaseTag) => {
|
|
2832
|
+
const result = git.extractTagAndVersion(releaseTag, tagRegexp, options);
|
|
2833
|
+
const version = semver.coerce(result.extractedVersion)?.version;
|
|
2834
|
+
const current = semver.coerce(ret.extractedVersion)?.version;
|
|
2835
|
+
if (version && semver.valid(version) && (!current || !semver.valid(current) || semver.gt(version, current, { loose: true }))) {
|
|
2836
|
+
return result;
|
|
2837
|
+
}
|
|
2838
|
+
return ret;
|
|
2839
|
+
},
|
|
2840
|
+
git.extractTagAndVersion(tags[0], tagRegexp, options)
|
|
2841
|
+
);
|
|
2842
|
+
}
|
|
2830
2843
|
async function getLatestGitTagForPattern(workspaceConfig, releaseTagPattern, additionalInterpolationData = {}, resolveTags, options) {
|
|
2831
2844
|
const { requireSemver, strictPreid, preid, checkAllBranchesWhen } = options;
|
|
2832
2845
|
try {
|
|
@@ -2851,27 +2864,17 @@ async function getLatestGitTagForPattern(workspaceConfig, releaseTagPattern, add
|
|
|
2851
2864
|
if (!matchingTags.length) {
|
|
2852
2865
|
return null;
|
|
2853
2866
|
}
|
|
2854
|
-
|
|
2867
|
+
chunkM4LUWNQR_cjs.writeDebug(
|
|
2855
2868
|
`Found ${matchingTags.length} matching tags out of ${tags.length} total tags for release tag pattern "${releaseTagPattern}" (Interpolated tag pattern: ${interpolatedTagPattern})`,
|
|
2856
2869
|
workspaceConfig
|
|
2857
2870
|
);
|
|
2858
2871
|
if (!strictPreid) {
|
|
2859
|
-
|
|
2860
|
-
`Not using strict preid, will use the
|
|
2872
|
+
chunkM4LUWNQR_cjs.writeTrace(
|
|
2873
|
+
`Not using strict preid, will use the greatest matching tag of project "${additionalInterpolationData.projectName}":
|
|
2874
|
+
${matchingTags.join(", ")}`,
|
|
2861
2875
|
workspaceConfig
|
|
2862
2876
|
);
|
|
2863
|
-
return matchingTags
|
|
2864
|
-
(ret, releaseTag) => {
|
|
2865
|
-
const result = git.extractTagAndVersion(releaseTag, tagRegexp, options);
|
|
2866
|
-
const version = semver.coerce(result.extractedVersion)?.version;
|
|
2867
|
-
const current = semver.coerce(ret.extractedVersion)?.version;
|
|
2868
|
-
if (version && semver.valid(version) && (!current || !semver.valid(current) || semver.gt(version, current, { loose: true }))) {
|
|
2869
|
-
return result;
|
|
2870
|
-
}
|
|
2871
|
-
return ret;
|
|
2872
|
-
},
|
|
2873
|
-
git.extractTagAndVersion(matchingTags[0], tagRegexp, options)
|
|
2874
|
-
);
|
|
2877
|
+
return compareTags(matchingTags, tagRegexp, options);
|
|
2875
2878
|
}
|
|
2876
2879
|
const stableReleaseTags = matchingTags.filter((tag) => {
|
|
2877
2880
|
const matches = tag.match(tagRegexp);
|
|
@@ -2879,7 +2882,7 @@ async function getLatestGitTagForPattern(workspaceConfig, releaseTagPattern, add
|
|
|
2879
2882
|
const [, version] = matches;
|
|
2880
2883
|
return version && !shared.isPrerelease(version);
|
|
2881
2884
|
});
|
|
2882
|
-
|
|
2885
|
+
chunkM4LUWNQR_cjs.writeDebug(
|
|
2883
2886
|
`Found ${stableReleaseTags.length} stable tags for release tag pattern "${releaseTagPattern}" (Interpolated tag pattern: ${interpolatedTagPattern})`,
|
|
2884
2887
|
workspaceConfig
|
|
2885
2888
|
);
|
|
@@ -2890,47 +2893,21 @@ async function getLatestGitTagForPattern(workspaceConfig, releaseTagPattern, add
|
|
|
2890
2893
|
const version = match.find((part) => part.match(SEMVER_REGEX));
|
|
2891
2894
|
return version && version.includes(`-${preid}.`);
|
|
2892
2895
|
});
|
|
2893
|
-
|
|
2896
|
+
chunkM4LUWNQR_cjs.writeDebug(
|
|
2894
2897
|
`Found ${preidReleaseTags.length} preid tags for release tag pattern "${releaseTagPattern}" (Interpolated tag pattern: ${interpolatedTagPattern})`,
|
|
2895
2898
|
workspaceConfig
|
|
2896
2899
|
);
|
|
2897
2900
|
if (preidReleaseTags.length > 0 && stableReleaseTags.length > 0) {
|
|
2898
|
-
const preidResult = preidReleaseTags
|
|
2899
|
-
|
|
2900
|
-
const result = git.extractTagAndVersion(releaseTag, tagRegexp, options);
|
|
2901
|
-
const version = semver.coerce(result.extractedVersion)?.version;
|
|
2902
|
-
const current = semver.coerce(ret.extractedVersion)?.version;
|
|
2903
|
-
if (version && semver.valid(version) && (!current || !semver.valid(current) || semver.gt(version, current, {
|
|
2904
|
-
loose: true
|
|
2905
|
-
}))) {
|
|
2906
|
-
return result;
|
|
2907
|
-
}
|
|
2908
|
-
return ret;
|
|
2909
|
-
},
|
|
2910
|
-
git.extractTagAndVersion(preidReleaseTags[0], tagRegexp, options)
|
|
2911
|
-
);
|
|
2912
|
-
const stableResult = stableReleaseTags.reduce(
|
|
2913
|
-
(ret, releaseTag) => {
|
|
2914
|
-
const result = git.extractTagAndVersion(releaseTag, tagRegexp, options);
|
|
2915
|
-
const version = semver.coerce(result.extractedVersion)?.version;
|
|
2916
|
-
const current = semver.coerce(ret.extractedVersion)?.version;
|
|
2917
|
-
if (version && semver.valid(version) && (!current || !semver.valid(current) || semver.gt(version, current, {
|
|
2918
|
-
loose: true
|
|
2919
|
-
}))) {
|
|
2920
|
-
return result;
|
|
2921
|
-
}
|
|
2922
|
-
return ret;
|
|
2923
|
-
},
|
|
2924
|
-
git.extractTagAndVersion(stableReleaseTags[0], tagRegexp, options)
|
|
2925
|
-
);
|
|
2901
|
+
const preidResult = compareTags(preidReleaseTags, tagRegexp, options);
|
|
2902
|
+
const stableResult = compareTags(stableReleaseTags, tagRegexp, options);
|
|
2926
2903
|
const preidBaseVersion = semver.coerce(preidResult.extractedVersion)?.version;
|
|
2927
2904
|
const stableVersion = semver.coerce(stableResult.extractedVersion)?.version;
|
|
2928
|
-
|
|
2905
|
+
chunkM4LUWNQR_cjs.writeDebug(
|
|
2929
2906
|
`Extracted preid version: ${preidBaseVersion} and stable version: ${stableVersion} for release tag pattern "${releaseTagPattern}" (Interpolated tag pattern: ${interpolatedTagPattern})`,
|
|
2930
2907
|
workspaceConfig
|
|
2931
2908
|
);
|
|
2932
2909
|
if (preidBaseVersion && stableVersion && semver.gte(stableVersion, preidBaseVersion)) {
|
|
2933
|
-
|
|
2910
|
+
chunkM4LUWNQR_cjs.writeDebug(
|
|
2934
2911
|
`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})`,
|
|
2935
2912
|
workspaceConfig
|
|
2936
2913
|
);
|
|
@@ -2939,43 +2916,19 @@ async function getLatestGitTagForPattern(workspaceConfig, releaseTagPattern, add
|
|
|
2939
2916
|
return preidResult;
|
|
2940
2917
|
}
|
|
2941
2918
|
if (preidReleaseTags.length > 0) {
|
|
2942
|
-
|
|
2919
|
+
chunkM4LUWNQR_cjs.writeDebug(
|
|
2943
2920
|
`Using latest preid tag for release tag pattern "${releaseTagPattern}" (Interpolated tag pattern: ${interpolatedTagPattern})`,
|
|
2944
2921
|
workspaceConfig
|
|
2945
2922
|
);
|
|
2946
|
-
return preidReleaseTags
|
|
2947
|
-
(ret, releaseTag) => {
|
|
2948
|
-
const result = git.extractTagAndVersion(releaseTag, tagRegexp, options);
|
|
2949
|
-
const version = semver.coerce(result.extractedVersion)?.version;
|
|
2950
|
-
const current = semver.coerce(ret.extractedVersion)?.version;
|
|
2951
|
-
if (version && semver.valid(version) && (!current || !semver.valid(current) || semver.gt(version, current, {
|
|
2952
|
-
loose: true
|
|
2953
|
-
}))) {
|
|
2954
|
-
return result;
|
|
2955
|
-
}
|
|
2956
|
-
return ret;
|
|
2957
|
-
},
|
|
2958
|
-
git.extractTagAndVersion(preidReleaseTags[0], tagRegexp, options)
|
|
2959
|
-
);
|
|
2923
|
+
return compareTags(preidReleaseTags, tagRegexp, options);
|
|
2960
2924
|
}
|
|
2961
2925
|
}
|
|
2962
2926
|
if (stableReleaseTags.length > 0) {
|
|
2963
|
-
|
|
2927
|
+
chunkM4LUWNQR_cjs.writeDebug(
|
|
2964
2928
|
`Using latest stable tag for release tag pattern "${releaseTagPattern}" (Interpolated tag pattern: ${interpolatedTagPattern})`,
|
|
2965
2929
|
workspaceConfig
|
|
2966
2930
|
);
|
|
2967
|
-
return stableReleaseTags
|
|
2968
|
-
(ret, releaseTag) => {
|
|
2969
|
-
const result = git.extractTagAndVersion(releaseTag, tagRegexp, options);
|
|
2970
|
-
const version = semver.coerce(result.extractedVersion)?.version;
|
|
2971
|
-
const current = semver.coerce(ret.extractedVersion)?.version;
|
|
2972
|
-
if (version && semver.valid(version) && (!current || !semver.valid(current) || semver.gt(version, current, { loose: true }))) {
|
|
2973
|
-
return result;
|
|
2974
|
-
}
|
|
2975
|
-
return ret;
|
|
2976
|
-
},
|
|
2977
|
-
git.extractTagAndVersion(stableReleaseTags[0], tagRegexp, options)
|
|
2978
|
-
);
|
|
2931
|
+
return compareTags(stableReleaseTags, tagRegexp, options);
|
|
2979
2932
|
}
|
|
2980
2933
|
return null;
|
|
2981
2934
|
} catch {
|
|
@@ -3025,7 +2978,7 @@ var StormGithubRemoteReleaseClient = class extends github.GithubRemoteReleaseCli
|
|
|
3025
2978
|
}
|
|
3026
2979
|
async createOrUpdateRelease(releaseVersion, changelogContents, latestCommit, { dryRun }) {
|
|
3027
2980
|
if (!this.workspaceConfig) {
|
|
3028
|
-
this.workspaceConfig = await
|
|
2981
|
+
this.workspaceConfig = await chunkM4LUWNQR_cjs.getWorkspaceConfig();
|
|
3029
2982
|
}
|
|
3030
2983
|
const name = releaseVersion.gitTag.includes("@") ? releaseVersion.gitTag.replace(new RegExp(`^@${this.workspaceConfig.name}/`), "").replace(/@.*$/, "") : releaseVersion.gitTag;
|
|
3031
2984
|
return super.createOrUpdateRelease(
|
|
@@ -3218,7 +3171,7 @@ async function format3(path, data) {
|
|
|
3218
3171
|
if (resolvedConfig) {
|
|
3219
3172
|
code = await prettier.format(
|
|
3220
3173
|
data,
|
|
3221
|
-
|
|
3174
|
+
chunkM4LUWNQR_cjs.defu(
|
|
3222
3175
|
{
|
|
3223
3176
|
absolutePath: path,
|
|
3224
3177
|
...resolvedConfig
|
|
@@ -3274,7 +3227,7 @@ var StormChangelogRenderer = class extends DefaultChangelogRenderer__default.def
|
|
|
3274
3227
|
}
|
|
3275
3228
|
async render() {
|
|
3276
3229
|
if (!this.workspaceConfig) {
|
|
3277
|
-
this.workspaceConfig = await
|
|
3230
|
+
this.workspaceConfig = await chunkM4LUWNQR_cjs.getWorkspaceConfig();
|
|
3278
3231
|
}
|
|
3279
3232
|
return super.render();
|
|
3280
3233
|
}
|
|
@@ -3581,7 +3534,7 @@ var DEFAULT_RUST_RELEASE_GROUP_CONFIG = {
|
|
|
3581
3534
|
var DEFAULT_RELEASE_CONFIG = {
|
|
3582
3535
|
conventionalCommits: DEFAULT_CONVENTIONAL_COMMITS_CONFIG2,
|
|
3583
3536
|
groups: {
|
|
3584
|
-
packages:
|
|
3537
|
+
packages: chunkM4LUWNQR_cjs.defu(
|
|
3585
3538
|
{
|
|
3586
3539
|
projects: ["packages/*"]
|
|
3587
3540
|
},
|
|
@@ -3589,7 +3542,7 @@ var DEFAULT_RELEASE_CONFIG = {
|
|
|
3589
3542
|
DEFAULT_INDEPENDENT_RELEASE_GROUP_CONFIG,
|
|
3590
3543
|
DEFAULT_RELEASE_GROUP_CONFIG
|
|
3591
3544
|
),
|
|
3592
|
-
crates:
|
|
3545
|
+
crates: chunkM4LUWNQR_cjs.defu(
|
|
3593
3546
|
{
|
|
3594
3547
|
projects: ["crates/*"]
|
|
3595
3548
|
},
|
|
@@ -3612,7 +3565,7 @@ var DEFAULT_RELEASE_CONFIG = {
|
|
|
3612
3565
|
}
|
|
3613
3566
|
};
|
|
3614
3567
|
function mergeReleaseGroupConfig(config5, defaultConfig, workspaceConfig) {
|
|
3615
|
-
return
|
|
3568
|
+
return chunkM4LUWNQR_cjs.defu(
|
|
3616
3569
|
{
|
|
3617
3570
|
...omit(defaultConfig, ["changelog", "version"]),
|
|
3618
3571
|
...config5
|
|
@@ -3643,7 +3596,7 @@ function getReleaseGroupConfig(projectGraph, releaseConfig, workspaceConfig) {
|
|
|
3643
3596
|
projectGraph.nodes
|
|
3644
3597
|
);
|
|
3645
3598
|
if (!matchingProjects.length) {
|
|
3646
|
-
|
|
3599
|
+
chunkM4LUWNQR_cjs.writeWarning(
|
|
3647
3600
|
`Release group "${name}" does not have any matching projects.`
|
|
3648
3601
|
);
|
|
3649
3602
|
return void 0;
|
|
@@ -3663,13 +3616,13 @@ function getReleaseGroupConfig(projectGraph, releaseConfig, workspaceConfig) {
|
|
|
3663
3616
|
ProjectTagConstants.Language.TAG_ID,
|
|
3664
3617
|
ProjectTagConstants.Language.TYPESCRIPT
|
|
3665
3618
|
) || projectGraph.nodes[project]?.data.metadata?.root && fs$1.existsSync(
|
|
3666
|
-
|
|
3619
|
+
chunkM4LUWNQR_cjs.joinPaths(
|
|
3667
3620
|
projectGraph.nodes[project]?.data.metadata?.root,
|
|
3668
3621
|
"package.json"
|
|
3669
3622
|
)
|
|
3670
3623
|
))
|
|
3671
3624
|
)) {
|
|
3672
|
-
defaultConfig =
|
|
3625
|
+
defaultConfig = chunkM4LUWNQR_cjs.defu(
|
|
3673
3626
|
group.projectsRelationship === "fixed" ? DEFAULT_FIXED_RELEASE_GROUP_CONFIG : DEFAULT_INDEPENDENT_RELEASE_GROUP_CONFIG,
|
|
3674
3627
|
DEFAULT_JS_RELEASE_GROUP_CONFIG,
|
|
3675
3628
|
DEFAULT_RELEASE_GROUP_CONFIG
|
|
@@ -3680,13 +3633,13 @@ function getReleaseGroupConfig(projectGraph, releaseConfig, workspaceConfig) {
|
|
|
3680
3633
|
ProjectTagConstants.Language.TAG_ID,
|
|
3681
3634
|
ProjectTagConstants.Language.RUST
|
|
3682
3635
|
) || projectGraph.nodes[project]?.data.metadata?.root && fs$1.existsSync(
|
|
3683
|
-
|
|
3636
|
+
chunkM4LUWNQR_cjs.joinPaths(
|
|
3684
3637
|
projectGraph.nodes[project]?.data.metadata?.root,
|
|
3685
3638
|
"Cargo.toml"
|
|
3686
3639
|
)
|
|
3687
3640
|
))
|
|
3688
3641
|
)) {
|
|
3689
|
-
defaultConfig =
|
|
3642
|
+
defaultConfig = chunkM4LUWNQR_cjs.defu(
|
|
3690
3643
|
group.projectsRelationship === "fixed" ? DEFAULT_FIXED_RELEASE_GROUP_CONFIG : DEFAULT_INDEPENDENT_RELEASE_GROUP_CONFIG,
|
|
3691
3644
|
DEFAULT_RUST_RELEASE_GROUP_CONFIG,
|
|
3692
3645
|
DEFAULT_RELEASE_GROUP_CONFIG
|
|
@@ -3700,13 +3653,13 @@ function getReleaseGroupConfig(projectGraph, releaseConfig, workspaceConfig) {
|
|
|
3700
3653
|
config5.projects = matchingProjects;
|
|
3701
3654
|
if (workspaceConfig?.workspaceRoot) {
|
|
3702
3655
|
if (config5.changelog?.renderer && typeof config5.changelog?.renderer === "string" && config5.changelog?.renderer?.toString().startsWith("./")) {
|
|
3703
|
-
config5.changelog.renderer =
|
|
3656
|
+
config5.changelog.renderer = chunkM4LUWNQR_cjs.joinPaths(
|
|
3704
3657
|
workspaceConfig.workspaceRoot,
|
|
3705
3658
|
config5.changelog.renderer
|
|
3706
3659
|
);
|
|
3707
3660
|
}
|
|
3708
3661
|
if (config5.version?.versionActions && config5.version.versionActions.startsWith("./")) {
|
|
3709
|
-
config5.version.versionActions =
|
|
3662
|
+
config5.version.versionActions = chunkM4LUWNQR_cjs.joinPaths(
|
|
3710
3663
|
workspaceConfig.workspaceRoot,
|
|
3711
3664
|
config5.version?.versionActions
|
|
3712
3665
|
);
|
|
@@ -3718,10 +3671,10 @@ function getReleaseGroupConfig(projectGraph, releaseConfig, workspaceConfig) {
|
|
|
3718
3671
|
}
|
|
3719
3672
|
function getReleaseConfig(projectGraph, releaseConfig, workspaceConfig, ignoreNxJsonConfig = false) {
|
|
3720
3673
|
let nxJson$1 = {};
|
|
3721
|
-
if (!ignoreNxJsonConfig && fs$1.existsSync(
|
|
3674
|
+
if (!ignoreNxJsonConfig && fs$1.existsSync(chunkM4LUWNQR_cjs.joinPaths(workspaceConfig.workspaceRoot, "nx.json"))) {
|
|
3722
3675
|
nxJson$1 = nxJson.readNxJson();
|
|
3723
3676
|
}
|
|
3724
|
-
const baseConfig =
|
|
3677
|
+
const baseConfig = chunkM4LUWNQR_cjs.defu(
|
|
3725
3678
|
{
|
|
3726
3679
|
changelog: {
|
|
3727
3680
|
renderOptions: {
|
|
@@ -3738,7 +3691,7 @@ function getReleaseConfig(projectGraph, releaseConfig, workspaceConfig, ignoreNx
|
|
|
3738
3691
|
if (releaseConfig?.groups && Object.keys(releaseConfig.groups).length > 0) {
|
|
3739
3692
|
groups = releaseConfig.groups;
|
|
3740
3693
|
if (nxJson$1.release?.groups && Object.keys(nxJson$1.release.groups).length > 0) {
|
|
3741
|
-
groups =
|
|
3694
|
+
groups = chunkM4LUWNQR_cjs.defu(
|
|
3742
3695
|
groups,
|
|
3743
3696
|
nxJson$1.release.groups
|
|
3744
3697
|
);
|
|
@@ -3758,7 +3711,7 @@ function getReleaseConfig(projectGraph, releaseConfig, workspaceConfig, ignoreNx
|
|
|
3758
3711
|
};
|
|
3759
3712
|
}
|
|
3760
3713
|
function formatConfigLog(config5) {
|
|
3761
|
-
return
|
|
3714
|
+
return chunkM4LUWNQR_cjs.formatLogMessage(config5, {
|
|
3762
3715
|
sort: true,
|
|
3763
3716
|
skip: ["workspaceConfig", "conventionalCommits"]
|
|
3764
3717
|
});
|
|
@@ -4171,7 +4124,7 @@ var ReleaseGraph = class _ReleaseGraph {
|
|
|
4171
4124
|
this.resolveRepositoryTags.bind(this),
|
|
4172
4125
|
options
|
|
4173
4126
|
);
|
|
4174
|
-
|
|
4127
|
+
chunkM4LUWNQR_cjs.writeDebug(
|
|
4175
4128
|
`Group release tag pattern: ${releaseTagPattern}
|
|
4176
4129
|
Project release tag pattern: ${projectReleaseTagPattern}
|
|
4177
4130
|
Group release tag: ${groupReleaseTag?.tag}
|
|
@@ -4195,7 +4148,7 @@ Project release tag: ${projectReleaseTag?.tag}`,
|
|
|
4195
4148
|
options
|
|
4196
4149
|
);
|
|
4197
4150
|
}
|
|
4198
|
-
|
|
4151
|
+
chunkM4LUWNQR_cjs.writeInfo(
|
|
4199
4152
|
`Resolved latest matching git tag for "${projectName}": ${latestMatchingGitTag?.tag} (version: ${latestMatchingGitTag?.extractedVersion})`,
|
|
4200
4153
|
this.workspaceConfig
|
|
4201
4154
|
);
|
|
@@ -4465,7 +4418,7 @@ var StormReleaseGroupProcessor = class _StormReleaseGroupProcessor extends relea
|
|
|
4465
4418
|
constructor(tree, workspaceConfig, projectGraph, nxReleaseConfig, releaseGraph, versionOptions) {
|
|
4466
4419
|
super(tree, projectGraph, nxReleaseConfig, releaseGraph, {
|
|
4467
4420
|
dryRun: !!versionOptions.dryRun,
|
|
4468
|
-
verbose: versionOptions.verbose ||
|
|
4421
|
+
verbose: versionOptions.verbose || chunkM4LUWNQR_cjs.isVerbose(workspaceConfig.logLevel),
|
|
4469
4422
|
firstRelease: !!versionOptions.firstRelease,
|
|
4470
4423
|
preid: versionOptions.preid ?? workspaceConfig.preid ?? "",
|
|
4471
4424
|
userGivenSpecifier: versionOptions.specifier,
|
|
@@ -4563,7 +4516,7 @@ var StormReleaseGroupProcessor = class _StormReleaseGroupProcessor extends relea
|
|
|
4563
4516
|
deletedFiles: deletedFilesForVersionActions
|
|
4564
4517
|
} = await afterAllProjectsVersioned(this.#tree.root, {
|
|
4565
4518
|
dryRun: this.versionOptions.dryRun,
|
|
4566
|
-
verbose: this.versionOptions.verbose ||
|
|
4519
|
+
verbose: this.versionOptions.verbose || chunkM4LUWNQR_cjs.isVerbose(this.workspaceConfig.logLevel),
|
|
4567
4520
|
rootVersionActionsOptions
|
|
4568
4521
|
});
|
|
4569
4522
|
for (const file of changedFilesForVersionActions) {
|
|
@@ -4596,7 +4549,7 @@ var StormReleaseGroupProcessor = class _StormReleaseGroupProcessor extends relea
|
|
|
4596
4549
|
let handleDockerVersion;
|
|
4597
4550
|
try {
|
|
4598
4551
|
const dockerVersionUtilsPath = "@nx/docker/release/version-utils";
|
|
4599
|
-
const { handleDockerVersion: _handleDockerVersion } =
|
|
4552
|
+
const { handleDockerVersion: _handleDockerVersion } = chunkM4LUWNQR_cjs.__require(dockerVersionUtilsPath);
|
|
4600
4553
|
handleDockerVersion = _handleDockerVersion;
|
|
4601
4554
|
} catch (e) {
|
|
4602
4555
|
console.error(
|
|
@@ -4684,12 +4637,12 @@ var StormReleaseGroupProcessor = class _StormReleaseGroupProcessor extends relea
|
|
|
4684
4637
|
for (const project of releaseGroup.projects) {
|
|
4685
4638
|
const currentVersion = this.#getCurrentCachedVersionForProject(project);
|
|
4686
4639
|
if (!currentVersion) {
|
|
4687
|
-
|
|
4640
|
+
chunkM4LUWNQR_cjs.writeTrace(
|
|
4688
4641
|
`No current version found for project ${project} in release group ${releaseGroup.name}, skipping version comparison.`,
|
|
4689
4642
|
this.workspaceConfig
|
|
4690
4643
|
);
|
|
4691
4644
|
} else {
|
|
4692
|
-
|
|
4645
|
+
chunkM4LUWNQR_cjs.writeDebug(
|
|
4693
4646
|
`Comparing versions for fixed group ${releaseGroup.name}: Current Greatest Version: ${fixedGroup.currentVersion || "none"}, Current Project Version: ${currentVersion} (project: ${project})`,
|
|
4694
4647
|
this.workspaceConfig
|
|
4695
4648
|
);
|
|
@@ -4715,7 +4668,7 @@ var StormReleaseGroupProcessor = class _StormReleaseGroupProcessor extends relea
|
|
|
4715
4668
|
reasonData: newVersionInputReasonData
|
|
4716
4669
|
};
|
|
4717
4670
|
}
|
|
4718
|
-
|
|
4671
|
+
chunkM4LUWNQR_cjs.writeDebug(
|
|
4719
4672
|
`Fixed release group ${releaseGroup.name} updated: Current Version: ${fixedGroup.currentVersion || "none"}, New Version: ${fixedGroup.newVersion?.input || "none"} (first project: ${project})`,
|
|
4720
4673
|
this.workspaceConfig
|
|
4721
4674
|
);
|
|
@@ -5168,7 +5121,7 @@ var StormReleaseGroupProcessor = class _StormReleaseGroupProcessor extends relea
|
|
|
5168
5121
|
var StormReleaseClient = class _StormReleaseClient extends release.ReleaseClient {
|
|
5169
5122
|
static async create(releaseConfig = {}, ignoreNxJsonConfig = false, workspaceConfig) {
|
|
5170
5123
|
if (!workspaceConfig) {
|
|
5171
|
-
workspaceConfig = await
|
|
5124
|
+
workspaceConfig = await chunkM4LUWNQR_cjs.getWorkspaceConfig();
|
|
5172
5125
|
}
|
|
5173
5126
|
const projectGraph = await devkit.createProjectGraphAsync({
|
|
5174
5127
|
exitOnError: true,
|
|
@@ -5179,7 +5132,7 @@ var StormReleaseClient = class _StormReleaseClient extends release.ReleaseClient
|
|
|
5179
5132
|
"Failed to load the project graph. Please run `nx reset`, then run the `storm-git commit` command again."
|
|
5180
5133
|
);
|
|
5181
5134
|
}
|
|
5182
|
-
|
|
5135
|
+
chunkM4LUWNQR_cjs.writeTrace(
|
|
5183
5136
|
`Provided release configuration:
|
|
5184
5137
|
${formatConfigLog(releaseConfig)}`,
|
|
5185
5138
|
workspaceConfig
|
|
@@ -5190,7 +5143,7 @@ ${formatConfigLog(releaseConfig)}`,
|
|
|
5190
5143
|
workspaceConfig,
|
|
5191
5144
|
ignoreNxJsonConfig
|
|
5192
5145
|
);
|
|
5193
|
-
|
|
5146
|
+
chunkM4LUWNQR_cjs.writeDebug(
|
|
5194
5147
|
`Resolved release configuration:
|
|
5195
5148
|
${formatConfigLog(config5)}`,
|
|
5196
5149
|
workspaceConfig
|
|
@@ -5227,11 +5180,11 @@ ${formatConfigLog(config5)}`,
|
|
|
5227
5180
|
*/
|
|
5228
5181
|
constructor(projectGraph, releaseConfig, workspaceConfig) {
|
|
5229
5182
|
super(releaseConfig, true);
|
|
5230
|
-
|
|
5183
|
+
chunkM4LUWNQR_cjs.writeDebug(
|
|
5231
5184
|
"Executing release with the following configuration",
|
|
5232
5185
|
workspaceConfig
|
|
5233
5186
|
);
|
|
5234
|
-
|
|
5187
|
+
chunkM4LUWNQR_cjs.writeDebug(releaseConfig, workspaceConfig);
|
|
5235
5188
|
this.projectGraph = projectGraph;
|
|
5236
5189
|
this.releaseConfig = releaseConfig;
|
|
5237
5190
|
this.workspaceConfig = workspaceConfig;
|
|
@@ -5259,7 +5212,7 @@ ${formatConfigLog(config5)}`,
|
|
|
5259
5212
|
groups: options.groups
|
|
5260
5213
|
},
|
|
5261
5214
|
firstRelease: !!options.firstRelease,
|
|
5262
|
-
verbose:
|
|
5215
|
+
verbose: chunkM4LUWNQR_cjs.isVerbose(this.workspaceConfig.logLevel)
|
|
5263
5216
|
},
|
|
5264
5217
|
this.workspaceConfig
|
|
5265
5218
|
);
|
|
@@ -5389,7 +5342,7 @@ ${formatConfigLog(config5)}`,
|
|
|
5389
5342
|
})),
|
|
5390
5343
|
this.releaseConfig.conventionalCommits
|
|
5391
5344
|
);
|
|
5392
|
-
|
|
5345
|
+
chunkM4LUWNQR_cjs.writeDebug(
|
|
5393
5346
|
`Running changelog generation for the ${releaseGroup.name} release group`,
|
|
5394
5347
|
this.workspaceConfig
|
|
5395
5348
|
);
|
|
@@ -5464,7 +5417,7 @@ ${formatConfigLog(config5)}`,
|
|
|
5464
5417
|
})),
|
|
5465
5418
|
this.releaseConfig.conventionalCommits
|
|
5466
5419
|
);
|
|
5467
|
-
|
|
5420
|
+
chunkM4LUWNQR_cjs.writeDebug(
|
|
5468
5421
|
`Running changelog generation for the ${releaseGroup.name} release group`,
|
|
5469
5422
|
this.workspaceConfig
|
|
5470
5423
|
);
|
|
@@ -5493,7 +5446,7 @@ ${formatConfigLog(config5)}`,
|
|
|
5493
5446
|
}
|
|
5494
5447
|
}
|
|
5495
5448
|
}
|
|
5496
|
-
|
|
5449
|
+
chunkM4LUWNQR_cjs.writeDebug(
|
|
5497
5450
|
`Generated changelogs for ${Object.keys(allProjectChangelogs).length} projects:
|
|
5498
5451
|
${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
5499
5452
|
`,
|
|
@@ -5522,7 +5475,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5522
5475
|
);
|
|
5523
5476
|
const changes = this.tree.listChanges();
|
|
5524
5477
|
if (!changes.length) {
|
|
5525
|
-
|
|
5478
|
+
chunkM4LUWNQR_cjs.writeWarning(
|
|
5526
5479
|
"No changes were detected for any changelog files, so no changelog entries will be generated.",
|
|
5527
5480
|
this.workspaceConfig
|
|
5528
5481
|
);
|
|
@@ -5544,7 +5497,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5544
5497
|
gitCommitArgs: options.gitCommitArgs || this.releaseConfig.changelog?.git?.commitArgs
|
|
5545
5498
|
});
|
|
5546
5499
|
latestCommit = await git.getCommitHash("HEAD");
|
|
5547
|
-
|
|
5500
|
+
chunkM4LUWNQR_cjs.writeDebug(
|
|
5548
5501
|
`Creating git tags: ${gitTagValues.join(", ")}`,
|
|
5549
5502
|
this.workspaceConfig
|
|
5550
5503
|
);
|
|
@@ -5557,7 +5510,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5557
5510
|
verbose: options.verbose
|
|
5558
5511
|
});
|
|
5559
5512
|
}
|
|
5560
|
-
|
|
5513
|
+
chunkM4LUWNQR_cjs.writeDebug(
|
|
5561
5514
|
`Pushing to git remote "${options.gitRemote ?? "origin"}"`,
|
|
5562
5515
|
this.workspaceConfig
|
|
5563
5516
|
);
|
|
@@ -5573,7 +5526,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5573
5526
|
return;
|
|
5574
5527
|
};
|
|
5575
5528
|
releaseVersion = async (options) => {
|
|
5576
|
-
const verbose = options.verbose ||
|
|
5529
|
+
const verbose = options.verbose || chunkM4LUWNQR_cjs.isVerbose(this.workspaceConfig.logLevel);
|
|
5577
5530
|
this.projectGraph = await devkit.createProjectGraphAsync({
|
|
5578
5531
|
exitOnError: true,
|
|
5579
5532
|
resetDaemonClient: true
|
|
@@ -5600,7 +5553,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5600
5553
|
this.workspaceConfig
|
|
5601
5554
|
);
|
|
5602
5555
|
if (releaseGraph.filterLog && process.env.NX_RELEASE_INTERNAL_SUPPRESS_FILTER_LOG !== "true") {
|
|
5603
|
-
|
|
5556
|
+
chunkM4LUWNQR_cjs.writeDebug(formatNxLog(releaseGraph.filterLog), this.workspaceConfig);
|
|
5604
5557
|
}
|
|
5605
5558
|
if (!options.specifier) {
|
|
5606
5559
|
const rawVersionPlans = await versionPlans.readRawVersionPlans();
|
|
@@ -5619,7 +5572,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5619
5572
|
}
|
|
5620
5573
|
} else {
|
|
5621
5574
|
if (verbose && releaseGraph.releaseGroups.some((g) => !!g.versionPlans)) {
|
|
5622
|
-
|
|
5575
|
+
chunkM4LUWNQR_cjs.writeDebug(
|
|
5623
5576
|
`Skipping version plan discovery as a specifier was provided`,
|
|
5624
5577
|
this.workspaceConfig
|
|
5625
5578
|
);
|
|
@@ -5629,7 +5582,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5629
5582
|
options.deleteVersionPlans = false;
|
|
5630
5583
|
}
|
|
5631
5584
|
if (this.releaseConfig.version?.preVersionCommand) {
|
|
5632
|
-
|
|
5585
|
+
chunkM4LUWNQR_cjs.writeDebug(
|
|
5633
5586
|
"Executing the following pre-version command: \n" + this.releaseConfig.version.preVersionCommand,
|
|
5634
5587
|
this.workspaceConfig
|
|
5635
5588
|
);
|
|
@@ -5665,7 +5618,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5665
5618
|
continue;
|
|
5666
5619
|
}
|
|
5667
5620
|
if (releaseGroup.version?.groupPreVersionCommand) {
|
|
5668
|
-
|
|
5621
|
+
chunkM4LUWNQR_cjs.writeDebug(
|
|
5669
5622
|
`Executing the ${releaseGroup.name} release group's pre-version command:
|
|
5670
5623
|
` + releaseGroup.version?.groupPreVersionCommand,
|
|
5671
5624
|
this.workspaceConfig
|
|
@@ -5725,7 +5678,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5725
5678
|
changed.forEach((f) => additionalChangedFiles.add(f));
|
|
5726
5679
|
deleted.forEach((f) => additionalDeletedFiles.add(f));
|
|
5727
5680
|
if (this.releaseConfig.docker && typeof this.releaseConfig.docker === "object" && this.releaseConfig.docker?.preVersionCommand) {
|
|
5728
|
-
|
|
5681
|
+
chunkM4LUWNQR_cjs.writeDebug(
|
|
5729
5682
|
`Executing the docker pre-version command:
|
|
5730
5683
|
` + this.releaseConfig.docker.preVersionCommand,
|
|
5731
5684
|
this.workspaceConfig
|
|
@@ -5762,7 +5715,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5762
5715
|
continue;
|
|
5763
5716
|
}
|
|
5764
5717
|
if (releaseGroup.docker?.groupPreVersionCommand) {
|
|
5765
|
-
|
|
5718
|
+
chunkM4LUWNQR_cjs.writeDebug(
|
|
5766
5719
|
`Executing the ${releaseGroup.name} release group's docker pre-version command:
|
|
5767
5720
|
` + releaseGroup.docker?.groupPreVersionCommand,
|
|
5768
5721
|
this.workspaceConfig
|
|
@@ -5793,7 +5746,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5793
5746
|
}
|
|
5794
5747
|
}
|
|
5795
5748
|
if (this.releaseConfig.docker || releaseGraph.releaseGroups.some((rg) => rg.docker)) {
|
|
5796
|
-
|
|
5749
|
+
chunkM4LUWNQR_cjs.writeWarning(
|
|
5797
5750
|
formatNxLog({
|
|
5798
5751
|
title: "Warning",
|
|
5799
5752
|
bodyLines: [
|
|
@@ -5850,7 +5803,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5850
5803
|
gitCommitArgs: options.gitCommitArgs || this.releaseConfig.version?.git?.commitArgs
|
|
5851
5804
|
});
|
|
5852
5805
|
} else if (options.stageChanges ?? this.releaseConfig.version?.git?.stageChanges) {
|
|
5853
|
-
|
|
5806
|
+
chunkM4LUWNQR_cjs.writeDebug(`Staging changed files with git`);
|
|
5854
5807
|
await git.gitAdd({
|
|
5855
5808
|
changedFiles,
|
|
5856
5809
|
deletedFiles,
|
|
@@ -5859,7 +5812,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5859
5812
|
});
|
|
5860
5813
|
}
|
|
5861
5814
|
if (options.gitTag ?? this.releaseConfig.version?.git?.tag) {
|
|
5862
|
-
|
|
5815
|
+
chunkM4LUWNQR_cjs.writeDebug(`Tagging commit with git`);
|
|
5863
5816
|
for (const tag of gitTagValues) {
|
|
5864
5817
|
await gitTag({
|
|
5865
5818
|
tag,
|
|
@@ -5871,7 +5824,7 @@ ${Object.keys(allProjectChangelogs).map((p) => ` - ${p}`).join("\n")}
|
|
|
5871
5824
|
}
|
|
5872
5825
|
}
|
|
5873
5826
|
if (options.gitPush ?? this.releaseConfig.version?.git?.push) {
|
|
5874
|
-
|
|
5827
|
+
chunkM4LUWNQR_cjs.writeDebug(`Pushing to git remote "${options.gitRemote ?? "origin"}"`);
|
|
5875
5828
|
await git.gitPush({
|
|
5876
5829
|
gitRemote: options.gitRemote,
|
|
5877
5830
|
dryRun: options.dryRun,
|
|
@@ -5902,7 +5855,7 @@ var runRelease = async (config5, {
|
|
|
5902
5855
|
throw new Error("The `GITHUB_ACTOR` environment variable is not set.");
|
|
5903
5856
|
}
|
|
5904
5857
|
if (!await isUserAnOrganizationMember(process.env.GITHUB_ACTOR, config5)) {
|
|
5905
|
-
|
|
5858
|
+
chunkM4LUWNQR_cjs.writeFatal(
|
|
5906
5859
|
"You must be a member of the Storm Software organization to run the release process.",
|
|
5907
5860
|
config5
|
|
5908
5861
|
);
|
|
@@ -5919,23 +5872,23 @@ var runRelease = async (config5, {
|
|
|
5919
5872
|
process.env.NODE_AUTH_TOKEN = process.env.NPM_TOKEN;
|
|
5920
5873
|
process.env.NPM_AUTH_TOKEN = process.env.NPM_TOKEN;
|
|
5921
5874
|
process.env.NPM_CONFIG_PROVENANCE = "true";
|
|
5922
|
-
|
|
5875
|
+
chunkM4LUWNQR_cjs.writeDebug("Creating Storm release client...", config5);
|
|
5923
5876
|
const releaseClient = await StormReleaseClient.create(
|
|
5924
5877
|
releaseConfig,
|
|
5925
5878
|
ignoreNxJsonConfig,
|
|
5926
5879
|
config5
|
|
5927
5880
|
);
|
|
5928
|
-
|
|
5881
|
+
chunkM4LUWNQR_cjs.writeDebug("Reading in the workspaces release configuration", config5);
|
|
5929
5882
|
const to = head || process.env.NX_HEAD;
|
|
5930
5883
|
const from = base || process.env.NX_BASE;
|
|
5931
|
-
|
|
5884
|
+
chunkM4LUWNQR_cjs.writeDebug(
|
|
5932
5885
|
`Using the following Git SHAs to determine the release content:
|
|
5933
5886
|
- From: ${from}
|
|
5934
5887
|
- To: ${to}
|
|
5935
5888
|
`,
|
|
5936
5889
|
config5
|
|
5937
5890
|
);
|
|
5938
|
-
|
|
5891
|
+
chunkM4LUWNQR_cjs.writeDebug("Determining the current release versions...", config5);
|
|
5939
5892
|
const { workspaceVersion, projectsVersionData, releaseGraph } = await releaseClient.releaseVersion({
|
|
5940
5893
|
dryRun,
|
|
5941
5894
|
verbose: true,
|
|
@@ -5952,9 +5905,9 @@ var runRelease = async (config5, {
|
|
|
5952
5905
|
from,
|
|
5953
5906
|
releaseGraph
|
|
5954
5907
|
});
|
|
5955
|
-
|
|
5908
|
+
chunkM4LUWNQR_cjs.writeDebug("Tagging commit with git", config5);
|
|
5956
5909
|
if (skipPublish) {
|
|
5957
|
-
|
|
5910
|
+
chunkM4LUWNQR_cjs.writeWarning(
|
|
5958
5911
|
"Skipping publishing packages since `skipPublish` was provided as `true` in the release options.",
|
|
5959
5912
|
config5
|
|
5960
5913
|
);
|
|
@@ -5963,7 +5916,7 @@ var runRelease = async (config5, {
|
|
|
5963
5916
|
(key) => projectsVersionData[key]?.newVersion
|
|
5964
5917
|
);
|
|
5965
5918
|
if (changedProjects.length > 0) {
|
|
5966
|
-
|
|
5919
|
+
chunkM4LUWNQR_cjs.writeInfo(
|
|
5967
5920
|
`Publishing release for ${changedProjects.length} ${changedProjects.length === 1 ? "project" : "projects"}:
|
|
5968
5921
|
${changedProjects.map((changedProject) => ` - ${changedProject}`).join("\n")}
|
|
5969
5922
|
`,
|
|
@@ -5987,10 +5940,10 @@ ${failedProjects.map((failedProject) => ` - ${failedProject} (Error Code: ${res
|
|
|
5987
5940
|
);
|
|
5988
5941
|
}
|
|
5989
5942
|
} else {
|
|
5990
|
-
|
|
5943
|
+
chunkM4LUWNQR_cjs.writeWarning("Skipped publishing packages.", config5);
|
|
5991
5944
|
}
|
|
5992
5945
|
}
|
|
5993
|
-
|
|
5946
|
+
chunkM4LUWNQR_cjs.writeSuccess("Completed the Storm workspace release process!", config5);
|
|
5994
5947
|
};
|
|
5995
5948
|
async function updatePackageManifests(projectsVersionData, config5) {
|
|
5996
5949
|
let projectGraph;
|
|
@@ -6005,7 +5958,7 @@ async function updatePackageManifests(projectsVersionData, config5) {
|
|
|
6005
5958
|
Object.keys(projectsVersionData).map(async (node) => {
|
|
6006
5959
|
const projectNode = projectGraph.nodes[node];
|
|
6007
5960
|
if (!projectNode?.data.root) {
|
|
6008
|
-
|
|
5961
|
+
chunkM4LUWNQR_cjs.writeWarning(
|
|
6009
5962
|
`Project node ${node} not found in the project graph. Skipping manifest update.`,
|
|
6010
5963
|
config5
|
|
6011
5964
|
);
|
|
@@ -6013,17 +5966,17 @@ async function updatePackageManifests(projectsVersionData, config5) {
|
|
|
6013
5966
|
}
|
|
6014
5967
|
const versionData = projectsVersionData[node];
|
|
6015
5968
|
if (projectNode?.data.root && versionData && versionData.newVersion !== null) {
|
|
6016
|
-
|
|
5969
|
+
chunkM4LUWNQR_cjs.writeTrace(
|
|
6017
5970
|
`Writing version ${versionData.newVersion} update to manifest file for ${node}
|
|
6018
5971
|
`,
|
|
6019
5972
|
config5
|
|
6020
5973
|
);
|
|
6021
|
-
const projectRoot =
|
|
5974
|
+
const projectRoot = chunkM4LUWNQR_cjs.joinPaths(
|
|
6022
5975
|
config5.workspaceRoot,
|
|
6023
5976
|
projectNode.data.root
|
|
6024
5977
|
);
|
|
6025
|
-
const packageJsonPath =
|
|
6026
|
-
const cargoTomlPath =
|
|
5978
|
+
const packageJsonPath = chunkM4LUWNQR_cjs.joinPaths(projectRoot, "package.json");
|
|
5979
|
+
const cargoTomlPath = chunkM4LUWNQR_cjs.joinPaths(projectRoot, "Cargo.toml");
|
|
6027
5980
|
if (fs$1.existsSync(packageJsonPath)) {
|
|
6028
5981
|
const packageJsonContent = await fs.readFile(packageJsonPath, "utf8");
|
|
6029
5982
|
const packageJson = JSON.parse(packageJsonContent);
|
|
@@ -6041,7 +5994,7 @@ async function updatePackageManifests(projectsVersionData, config5) {
|
|
|
6041
5994
|
})
|
|
6042
5995
|
);
|
|
6043
5996
|
} else {
|
|
6044
|
-
|
|
5997
|
+
chunkM4LUWNQR_cjs.writeWarning("No project nodes found. Skipping manifest updates.", config5);
|
|
6045
5998
|
}
|
|
6046
5999
|
}
|
|
6047
6000
|
|
|
@@ -6049,8 +6002,8 @@ async function updatePackageManifests(projectsVersionData, config5) {
|
|
|
6049
6002
|
var _config = {};
|
|
6050
6003
|
function createProgram(config5) {
|
|
6051
6004
|
_config = config5;
|
|
6052
|
-
|
|
6053
|
-
const root =
|
|
6005
|
+
chunkM4LUWNQR_cjs.writeInfo(`${chunkM4LUWNQR_cjs.brandIcon(_config)} Running Storm Git Tools`, config5);
|
|
6006
|
+
const root = chunkM4LUWNQR_cjs.findWorkspaceRootSafe(process.cwd());
|
|
6054
6007
|
process.env.STORM_WORKSPACE_ROOT ??= root;
|
|
6055
6008
|
process.env.NX_WORKSPACE_ROOT_PATH ??= root;
|
|
6056
6009
|
if (root) {
|
|
@@ -6097,12 +6050,12 @@ async function commitAction({
|
|
|
6097
6050
|
dryRun = false
|
|
6098
6051
|
}) {
|
|
6099
6052
|
try {
|
|
6100
|
-
|
|
6101
|
-
`${
|
|
6053
|
+
chunkM4LUWNQR_cjs.writeInfo(
|
|
6054
|
+
`${chunkM4LUWNQR_cjs.brandIcon(typeof config5 === "string" ? {} : config5)} Preparing to commit your changes. Please provide the requested details below...`,
|
|
6102
6055
|
_config
|
|
6103
6056
|
);
|
|
6104
6057
|
await runCommit(config5, dryRun);
|
|
6105
|
-
|
|
6058
|
+
chunkM4LUWNQR_cjs.writeSuccess(
|
|
6106
6059
|
`\u2714 Storm Commit processing completed successfully!
|
|
6107
6060
|
|
|
6108
6061
|
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}
|
|
@@ -6110,7 +6063,7 @@ Note: Please run "pnpm push" to upload these changes to the remote ${_config.nam
|
|
|
6110
6063
|
_config
|
|
6111
6064
|
);
|
|
6112
6065
|
} catch (error) {
|
|
6113
|
-
|
|
6066
|
+
chunkM4LUWNQR_cjs.writeFatal(
|
|
6114
6067
|
`A fatal error occurred while running commit action:
|
|
6115
6068
|
|
|
6116
6069
|
${error.message}${error.stack ? `
|
|
@@ -6125,17 +6078,17 @@ Please fix any errors and try committing again.`,
|
|
|
6125
6078
|
}
|
|
6126
6079
|
async function readmeAction(options) {
|
|
6127
6080
|
try {
|
|
6128
|
-
|
|
6129
|
-
`${
|
|
6081
|
+
chunkM4LUWNQR_cjs.writeInfo(
|
|
6082
|
+
`${chunkM4LUWNQR_cjs.brandIcon(_config)} Formatting the workspace's README.md files`,
|
|
6130
6083
|
_config
|
|
6131
6084
|
);
|
|
6132
6085
|
await runReadme(options);
|
|
6133
|
-
|
|
6086
|
+
chunkM4LUWNQR_cjs.writeSuccess(
|
|
6134
6087
|
"\u2714 Formatting of the workspace's README.md files is complete\n",
|
|
6135
6088
|
_config
|
|
6136
6089
|
);
|
|
6137
6090
|
} catch (error) {
|
|
6138
|
-
|
|
6091
|
+
chunkM4LUWNQR_cjs.writeFatal(
|
|
6139
6092
|
`A fatal error occurred while running README format action:
|
|
6140
6093
|
|
|
6141
6094
|
${error.message}`
|
|
@@ -6150,8 +6103,8 @@ async function releaseAction({
|
|
|
6150
6103
|
dryRun
|
|
6151
6104
|
}) {
|
|
6152
6105
|
try {
|
|
6153
|
-
|
|
6154
|
-
`${
|
|
6106
|
+
chunkM4LUWNQR_cjs.writeInfo(
|
|
6107
|
+
`${chunkM4LUWNQR_cjs.brandIcon(_config)} Running the Storm Release and Publish process on the workspace`,
|
|
6155
6108
|
_config
|
|
6156
6109
|
);
|
|
6157
6110
|
await runRelease(_config, {
|
|
@@ -6160,9 +6113,9 @@ async function releaseAction({
|
|
|
6160
6113
|
base,
|
|
6161
6114
|
head
|
|
6162
6115
|
});
|
|
6163
|
-
|
|
6116
|
+
chunkM4LUWNQR_cjs.writeSuccess("\u2714 Release completed successfully!\n", _config);
|
|
6164
6117
|
} catch (error) {
|
|
6165
|
-
|
|
6118
|
+
chunkM4LUWNQR_cjs.writeFatal(
|
|
6166
6119
|
`A fatal error occurred while running release action:
|
|
6167
6120
|
|
|
6168
6121
|
${error.message} ${error.stack ? `
|
|
@@ -6176,17 +6129,17 @@ Stacktrace: ${error.stack}` : ""}`,
|
|
|
6176
6129
|
}
|
|
6177
6130
|
async function commitLintAction(options) {
|
|
6178
6131
|
try {
|
|
6179
|
-
|
|
6180
|
-
`${
|
|
6132
|
+
chunkM4LUWNQR_cjs.writeInfo(
|
|
6133
|
+
`${chunkM4LUWNQR_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.`,
|
|
6181
6134
|
_config
|
|
6182
6135
|
);
|
|
6183
6136
|
await runCommitLint(_config, options);
|
|
6184
|
-
|
|
6137
|
+
chunkM4LUWNQR_cjs.writeSuccess(
|
|
6185
6138
|
"\u2714 Linting the commit messages completed successfully!\n",
|
|
6186
6139
|
_config
|
|
6187
6140
|
);
|
|
6188
6141
|
} catch (error) {
|
|
6189
|
-
|
|
6142
|
+
chunkM4LUWNQR_cjs.writeFatal(
|
|
6190
6143
|
`A fatal error occurred while linting the commit messages:
|
|
6191
6144
|
|
|
6192
6145
|
${error.message}`,
|
|
@@ -6197,14 +6150,14 @@ ${error.message}`,
|
|
|
6197
6150
|
}
|
|
6198
6151
|
async function postCheckoutAction({ files }) {
|
|
6199
6152
|
try {
|
|
6200
|
-
|
|
6201
|
-
`${
|
|
6153
|
+
chunkM4LUWNQR_cjs.writeInfo(
|
|
6154
|
+
`${chunkM4LUWNQR_cjs.brandIcon(_config)} Running the Storm post-checkout git hook for ${files.length} files in the workspace...`,
|
|
6202
6155
|
_config
|
|
6203
6156
|
);
|
|
6204
|
-
await
|
|
6205
|
-
|
|
6157
|
+
await chunkO3X5QPCQ_cjs.postCheckoutHook(_config, files);
|
|
6158
|
+
chunkM4LUWNQR_cjs.writeSuccess("\u2714 Post-checkout hook completed successfully!\n", _config);
|
|
6206
6159
|
} catch (error) {
|
|
6207
|
-
|
|
6160
|
+
chunkM4LUWNQR_cjs.writeFatal(
|
|
6208
6161
|
`A fatal error occurred while running the post-checkout hook:
|
|
6209
6162
|
|
|
6210
6163
|
${error.message}`,
|
|
@@ -6215,14 +6168,14 @@ ${error.message}`,
|
|
|
6215
6168
|
}
|
|
6216
6169
|
async function postCommitAction({ files }) {
|
|
6217
6170
|
try {
|
|
6218
|
-
|
|
6219
|
-
`${
|
|
6171
|
+
chunkM4LUWNQR_cjs.writeInfo(
|
|
6172
|
+
`${chunkM4LUWNQR_cjs.brandIcon(_config)} Running the Storm post-commit git hook for ${files.length} files in the workspace...`,
|
|
6220
6173
|
_config
|
|
6221
6174
|
);
|
|
6222
|
-
await
|
|
6223
|
-
|
|
6175
|
+
await chunkZMVLIEV4_cjs.postCommitHook(_config, files);
|
|
6176
|
+
chunkM4LUWNQR_cjs.writeSuccess("\u2714 Post-commit hook completed successfully!\n", _config);
|
|
6224
6177
|
} catch (error) {
|
|
6225
|
-
|
|
6178
|
+
chunkM4LUWNQR_cjs.writeFatal(
|
|
6226
6179
|
`A fatal error occurred while running the post-commit hook:
|
|
6227
6180
|
|
|
6228
6181
|
${error.message}`,
|
|
@@ -6233,14 +6186,14 @@ ${error.message}`,
|
|
|
6233
6186
|
}
|
|
6234
6187
|
async function postMergeAction({ files }) {
|
|
6235
6188
|
try {
|
|
6236
|
-
|
|
6237
|
-
`${
|
|
6189
|
+
chunkM4LUWNQR_cjs.writeInfo(
|
|
6190
|
+
`${chunkM4LUWNQR_cjs.brandIcon(_config)} Running the Storm post-merge git hook for ${files.length} files in the workspace...`,
|
|
6238
6191
|
_config
|
|
6239
6192
|
);
|
|
6240
|
-
await
|
|
6241
|
-
|
|
6193
|
+
await chunkB56KWU7H_cjs.postMergeHook(_config, files);
|
|
6194
|
+
chunkM4LUWNQR_cjs.writeSuccess("\u2714 Post-merge hook completed successfully!\n", _config);
|
|
6242
6195
|
} catch (error) {
|
|
6243
|
-
|
|
6196
|
+
chunkM4LUWNQR_cjs.writeFatal(
|
|
6244
6197
|
`A fatal error occurred while running the post-merge hook:
|
|
6245
6198
|
|
|
6246
6199
|
${error.message}`,
|
|
@@ -6251,14 +6204,14 @@ ${error.message}`,
|
|
|
6251
6204
|
}
|
|
6252
6205
|
async function preCommitAction({ files }) {
|
|
6253
6206
|
try {
|
|
6254
|
-
|
|
6255
|
-
`${
|
|
6207
|
+
chunkM4LUWNQR_cjs.writeInfo(
|
|
6208
|
+
`${chunkM4LUWNQR_cjs.brandIcon(_config)} Running the Storm pre-commit git hook for ${files.length} files in the workspace...`,
|
|
6256
6209
|
_config
|
|
6257
6210
|
);
|
|
6258
|
-
await
|
|
6259
|
-
|
|
6211
|
+
await chunk6AN4QYAN_cjs.preCommitHook(_config, files);
|
|
6212
|
+
chunkM4LUWNQR_cjs.writeSuccess("\u2714 Pre-commit hook completed successfully!\n", _config);
|
|
6260
6213
|
} catch (error) {
|
|
6261
|
-
|
|
6214
|
+
chunkM4LUWNQR_cjs.writeFatal(
|
|
6262
6215
|
`A fatal error occurred while running the pre-commit hook:
|
|
6263
6216
|
|
|
6264
6217
|
${error.message}`,
|
|
@@ -6269,14 +6222,14 @@ ${error.message}`,
|
|
|
6269
6222
|
}
|
|
6270
6223
|
async function prePushAction({ files }) {
|
|
6271
6224
|
try {
|
|
6272
|
-
|
|
6273
|
-
`${
|
|
6225
|
+
chunkM4LUWNQR_cjs.writeInfo(
|
|
6226
|
+
`${chunkM4LUWNQR_cjs.brandIcon(_config)} Running the Storm pre-push git hook for ${files.length} files in the workspace...`,
|
|
6274
6227
|
_config
|
|
6275
6228
|
);
|
|
6276
|
-
await
|
|
6277
|
-
|
|
6229
|
+
await chunkAY74OKG5_cjs.prePushHook(_config, files);
|
|
6230
|
+
chunkM4LUWNQR_cjs.writeSuccess("\u2714 Pre-push hook completed successfully!\n", _config);
|
|
6278
6231
|
} catch (error) {
|
|
6279
|
-
|
|
6232
|
+
chunkM4LUWNQR_cjs.writeFatal(
|
|
6280
6233
|
`A fatal error occurred while running the pre-push hook:
|
|
6281
6234
|
|
|
6282
6235
|
${error.message}`,
|
|
@@ -6287,14 +6240,14 @@ ${error.message}`,
|
|
|
6287
6240
|
}
|
|
6288
6241
|
async function prepareAction() {
|
|
6289
6242
|
try {
|
|
6290
|
-
|
|
6291
|
-
`${
|
|
6243
|
+
chunkM4LUWNQR_cjs.writeInfo(
|
|
6244
|
+
`${chunkM4LUWNQR_cjs.brandIcon(_config)} Running the Storm prepare git hook for the workspace...`,
|
|
6292
6245
|
_config
|
|
6293
6246
|
);
|
|
6294
|
-
await
|
|
6295
|
-
|
|
6247
|
+
await chunkU7X6DX3D_cjs.prepareHook(_config);
|
|
6248
|
+
chunkM4LUWNQR_cjs.writeSuccess("\u2714 Prepare hook completed successfully!\n", _config);
|
|
6296
6249
|
} catch (error) {
|
|
6297
|
-
|
|
6250
|
+
chunkM4LUWNQR_cjs.writeFatal(
|
|
6298
6251
|
`A fatal error occurred while running the prepare hook:
|
|
6299
6252
|
|
|
6300
6253
|
${error.message}`,
|
|
@@ -6306,18 +6259,18 @@ ${error.message}`,
|
|
|
6306
6259
|
|
|
6307
6260
|
// bin/git.ts
|
|
6308
6261
|
void (async () => {
|
|
6309
|
-
const config5 = await
|
|
6262
|
+
const config5 = await chunkM4LUWNQR_cjs.getConfig();
|
|
6310
6263
|
try {
|
|
6311
|
-
|
|
6264
|
+
chunkM4LUWNQR_cjs.handleProcess(config5);
|
|
6312
6265
|
const program = createProgram(config5);
|
|
6313
6266
|
await program.parseAsync(process.argv);
|
|
6314
|
-
|
|
6267
|
+
chunkM4LUWNQR_cjs.writeSuccess(
|
|
6315
6268
|
`\u2714 Git ${process.argv && process.argv.length >= 3 && process.argv[2] ? process.argv[2] : "tool"} processing completed successfully!`,
|
|
6316
6269
|
config5
|
|
6317
6270
|
);
|
|
6318
|
-
|
|
6271
|
+
chunkM4LUWNQR_cjs.exitWithSuccess(config5);
|
|
6319
6272
|
} catch (error) {
|
|
6320
|
-
|
|
6273
|
+
chunkM4LUWNQR_cjs.exitWithError(config5);
|
|
6321
6274
|
process.exit(1);
|
|
6322
6275
|
}
|
|
6323
6276
|
})();
|