@storm-software/git-tools 2.121.1 → 2.121.2
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 -2
- package/bin/git.cjs +7 -7
- package/bin/git.js +7 -7
- package/package.json +5 -5
package/README.md
CHANGED
|
@@ -21,7 +21,7 @@ This package is part of the <b>⚡Storm-Ops</b> monorepo. The Storm-Ops packages
|
|
|
21
21
|
|
|
22
22
|
<h3 align="center">💻 Visit <a href="https://stormsoftware.com" target="_blank">stormsoftware.com</a> to stay up to date with this developer</h3><br />
|
|
23
23
|
|
|
24
|
-
[](https://prettier.io/) [](http://nx.dev/) [](https://nextjs.org/) [](http://commitizen.github.io/cz-cli/)  [](https://fumadocs.vercel.app/) 
|
|
25
25
|
|
|
26
26
|
<!-- prettier-ignore-start -->
|
|
27
27
|
<!-- markdownlint-disable -->
|
|
@@ -40,7 +40,6 @@ This package is part of the <b>⚡Storm-Ops</b> monorepo. The Storm-Ops packages
|
|
|
40
40
|
|
|
41
41
|
<!-- START doctoc -->
|
|
42
42
|
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
|
43
|
-
|
|
44
43
|
## Table of Contents
|
|
45
44
|
|
|
46
45
|
- [Storm Git Tools](#storm-git-tools)
|
package/bin/git.cjs
CHANGED
|
@@ -1329,7 +1329,7 @@ async function createState(workspaceConfig, configPath) {
|
|
|
1329
1329
|
return state;
|
|
1330
1330
|
}
|
|
1331
1331
|
var MAX_LINE_WIDTH = 72;
|
|
1332
|
-
var formatCommitMessage = (state) => {
|
|
1332
|
+
var formatCommitMessage = (state, workspaceConfig) => {
|
|
1333
1333
|
const { config: config5, answers } = state;
|
|
1334
1334
|
const wrapOptions = {
|
|
1335
1335
|
indent: "",
|
|
@@ -1339,17 +1339,17 @@ var formatCommitMessage = (state) => {
|
|
|
1339
1339
|
if (typeof answers.type !== "string") {
|
|
1340
1340
|
throw new Error("Invalid commit type.");
|
|
1341
1341
|
}
|
|
1342
|
-
if (typeof answers.scope !== "string") {
|
|
1343
|
-
throw new Error("Invalid commit scope.");
|
|
1344
|
-
}
|
|
1345
1342
|
if (typeof answers.subject !== "string") {
|
|
1346
1343
|
throw new Error("Invalid subject type.");
|
|
1347
1344
|
}
|
|
1345
|
+
if (workspaceConfig.variant !== "minimal" && typeof answers.scope !== "string") {
|
|
1346
|
+
throw new Error("Invalid commit scope.");
|
|
1347
|
+
}
|
|
1348
1348
|
const emoji = answers.type?.[answers.type]?.emoji ? answers.type[answers.type].emoji : "";
|
|
1349
|
-
const scope = answers.scope ? answers.scope.trim() : "";
|
|
1349
|
+
const scope = workspaceConfig.variant !== "minimal" && typeof answers.scope === "string" && answers.scope ? answers.scope.trim() : "";
|
|
1350
1350
|
const subject = answers.subject?.trim();
|
|
1351
1351
|
const type = answers.type;
|
|
1352
|
-
const format2 = config5.prompt.settings.format || "{type}({scope}): {emoji}{subject}";
|
|
1352
|
+
const format2 = config5.prompt.settings.format || (workspaceConfig.variant !== "minimal" ? "{type}({scope}): {emoji}{subject}" : "{type}: {emoji}{subject}");
|
|
1353
1353
|
const body = answers.body && typeof answers.body === "string" ? wrap__default.default(answers.body || "", wrapOptions) : "";
|
|
1354
1354
|
const breaking = answers.breakingBody && typeof answers.breakingBody === "string" ? wrap__default.default(answers.breakingBody || "", wrapOptions) : "";
|
|
1355
1355
|
const issues = answers.issuesBody && typeof answers.issuesBody === "string" ? wrap__default.default(answers.issuesBody || "", wrapOptions) : "";
|
|
@@ -1392,7 +1392,7 @@ async function runCommit(commitizenFile, dryRun = false) {
|
|
|
1392
1392
|
{#CCCCCC Please provide the requested details below...}
|
|
1393
1393
|
`);
|
|
1394
1394
|
state.answers = await askQuestions(state);
|
|
1395
|
-
const message = formatCommitMessage(state);
|
|
1395
|
+
const message = formatCommitMessage(state, workspaceConfig);
|
|
1396
1396
|
const commitMsgFile = chunk7V324BCR_cjs.joinPaths(getGitDir(), "COMMIT_EDITMSG");
|
|
1397
1397
|
console.log(chalkTemplate__default.default`
|
|
1398
1398
|
{bold.#999999 ----------------------------------------}
|
package/bin/git.js
CHANGED
|
@@ -1311,7 +1311,7 @@ async function createState(workspaceConfig, configPath) {
|
|
|
1311
1311
|
return state;
|
|
1312
1312
|
}
|
|
1313
1313
|
var MAX_LINE_WIDTH = 72;
|
|
1314
|
-
var formatCommitMessage = (state) => {
|
|
1314
|
+
var formatCommitMessage = (state, workspaceConfig) => {
|
|
1315
1315
|
const { config: config5, answers } = state;
|
|
1316
1316
|
const wrapOptions = {
|
|
1317
1317
|
indent: "",
|
|
@@ -1321,17 +1321,17 @@ var formatCommitMessage = (state) => {
|
|
|
1321
1321
|
if (typeof answers.type !== "string") {
|
|
1322
1322
|
throw new Error("Invalid commit type.");
|
|
1323
1323
|
}
|
|
1324
|
-
if (typeof answers.scope !== "string") {
|
|
1325
|
-
throw new Error("Invalid commit scope.");
|
|
1326
|
-
}
|
|
1327
1324
|
if (typeof answers.subject !== "string") {
|
|
1328
1325
|
throw new Error("Invalid subject type.");
|
|
1329
1326
|
}
|
|
1327
|
+
if (workspaceConfig.variant !== "minimal" && typeof answers.scope !== "string") {
|
|
1328
|
+
throw new Error("Invalid commit scope.");
|
|
1329
|
+
}
|
|
1330
1330
|
const emoji = answers.type?.[answers.type]?.emoji ? answers.type[answers.type].emoji : "";
|
|
1331
|
-
const scope = answers.scope ? answers.scope.trim() : "";
|
|
1331
|
+
const scope = workspaceConfig.variant !== "minimal" && typeof answers.scope === "string" && answers.scope ? answers.scope.trim() : "";
|
|
1332
1332
|
const subject = answers.subject?.trim();
|
|
1333
1333
|
const type = answers.type;
|
|
1334
|
-
const format2 = config5.prompt.settings.format || "{type}({scope}): {emoji}{subject}";
|
|
1334
|
+
const format2 = config5.prompt.settings.format || (workspaceConfig.variant !== "minimal" ? "{type}({scope}): {emoji}{subject}" : "{type}: {emoji}{subject}");
|
|
1335
1335
|
const body = answers.body && typeof answers.body === "string" ? wrap(answers.body || "", wrapOptions) : "";
|
|
1336
1336
|
const breaking = answers.breakingBody && typeof answers.breakingBody === "string" ? wrap(answers.breakingBody || "", wrapOptions) : "";
|
|
1337
1337
|
const issues = answers.issuesBody && typeof answers.issuesBody === "string" ? wrap(answers.issuesBody || "", wrapOptions) : "";
|
|
@@ -1374,7 +1374,7 @@ async function runCommit(commitizenFile, dryRun = false) {
|
|
|
1374
1374
|
{#CCCCCC Please provide the requested details below...}
|
|
1375
1375
|
`);
|
|
1376
1376
|
state.answers = await askQuestions(state);
|
|
1377
|
-
const message = formatCommitMessage(state);
|
|
1377
|
+
const message = formatCommitMessage(state, workspaceConfig);
|
|
1378
1378
|
const commitMsgFile = joinPaths(getGitDir(), "COMMIT_EDITMSG");
|
|
1379
1379
|
console.log(chalkTemplate`
|
|
1380
1380
|
{bold.#999999 ----------------------------------------}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@storm-software/git-tools",
|
|
3
|
-
"version": "2.121.
|
|
3
|
+
"version": "2.121.2",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Tools for managing Git repositories within a Nx workspace.",
|
|
6
6
|
"repository": {
|
|
@@ -185,8 +185,8 @@
|
|
|
185
185
|
"@inquirer/prompts": "7.2.1",
|
|
186
186
|
"@nx/devkit": "^21.4.1",
|
|
187
187
|
"@nx/js": "^21.4.1",
|
|
188
|
-
"@storm-software/config": "^1.131.
|
|
189
|
-
"@storm-software/config-tools": "^1.185.
|
|
188
|
+
"@storm-software/config": "^1.131.2",
|
|
189
|
+
"@storm-software/config-tools": "^1.185.2",
|
|
190
190
|
"@textlint/ast-node-types": "14.4.2",
|
|
191
191
|
"@textlint/markdown-to-ast": "14.4.2",
|
|
192
192
|
"anchor-markdown-header": "0.7.0",
|
|
@@ -194,7 +194,7 @@
|
|
|
194
194
|
"axios": "1.8.2",
|
|
195
195
|
"chalk": "^4.1.2",
|
|
196
196
|
"chalk-template": "1.1.0",
|
|
197
|
-
"conventional-changelog-storm-software": "^0.1.
|
|
197
|
+
"conventional-changelog-storm-software": "^0.1.2",
|
|
198
198
|
"htmlparser2": "10.0.0",
|
|
199
199
|
"jsonc-parser": "3.2.1",
|
|
200
200
|
"nx": "^21.4.1",
|
|
@@ -216,5 +216,5 @@
|
|
|
216
216
|
"tsup": "8.4.0"
|
|
217
217
|
},
|
|
218
218
|
"publishConfig": { "access": "public" },
|
|
219
|
-
"gitHead": "
|
|
219
|
+
"gitHead": "a65b87ef2f82c159996a3c45db514650df5d86ee"
|
|
220
220
|
}
|