@storm-software/git-tools 2.67.0 → 2.67.1
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/CHANGELOG.md +6 -0
- package/README.md +1 -1
- package/bin/git.js +21 -20
- package/bin/post-checkout.js +21 -20
- package/bin/post-commit.js +21 -20
- package/bin/post-merge.js +21 -20
- package/bin/pre-commit.js +21 -20
- package/bin/pre-install.js +21 -20
- package/bin/pre-push.js +21 -20
- package/bin/prepare.js +21 -20
- package/bin/version-warning.js +21 -20
- package/package.json +1 -1
- package/src/cli/index.js +21 -20
- package/src/commit/index.js +10 -10
- package/src/commitizen/index.js +10 -10
- package/src/index.js +21 -20
- package/src/release/index.js +10 -10
package/CHANGELOG.md
CHANGED
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 -->
|
package/bin/git.js
CHANGED
|
@@ -230245,7 +230245,7 @@ var getLogLevelLabel = (logLevel = LogLevel.INFO) => {
|
|
|
230245
230245
|
var getLogFn = (logLevel = LogLevel.INFO, config2 = {}) => {
|
|
230246
230246
|
const _chalk = getChalk();
|
|
230247
230247
|
const colors = !config2.colors?.dark && !config2.colors?.["base"] && !config2.colors?.["base"]?.dark ? DEFAULT_COLOR_CONFIG : config2.colors?.dark && typeof config2.colors.dark === "string" ? config2.colors : config2.colors?.["base"]?.dark && typeof config2.colors["base"].dark === "string" ? config2.colors["base"].dark : config2.colors?.["base"] ? config2.colors?.["base"] : DEFAULT_COLOR_CONFIG;
|
|
230248
|
-
const configLogLevel = config2.logLevel
|
|
230248
|
+
const configLogLevel = config2.logLevel || process.env.STORM_LOG_LEVEL || LogLevelLabel.INFO;
|
|
230249
230249
|
if (typeof logLevel === "number" && (logLevel >= getLogLevel(configLogLevel) || logLevel <= LogLevel.SILENT) || typeof logLevel === "string" && getLogLevel(logLevel) >= getLogLevel(configLogLevel)) {
|
|
230250
230250
|
return (_15) => {
|
|
230251
230251
|
};
|
|
@@ -230253,9 +230253,9 @@ var getLogFn = (logLevel = LogLevel.INFO, config2 = {}) => {
|
|
|
230253
230253
|
if (typeof logLevel === "number" && LogLevel.FATAL >= logLevel || typeof logLevel === "string" && LogLevel.FATAL >= getLogLevel(logLevel)) {
|
|
230254
230254
|
return (message) => {
|
|
230255
230255
|
console.error(
|
|
230256
|
-
`${_chalk.bold.hex(colors.
|
|
230256
|
+
`${_chalk.bold.hex(colors.fatal ?? "#7d1a1a")(">")} ${_chalk.bold.bgHex(colors.fatal ?? "#7d1a1a").whiteBright(
|
|
230257
230257
|
" \u{1F480} Fatal "
|
|
230258
|
-
)} ${_chalk.hex(colors.
|
|
230258
|
+
)} ${_chalk.hex(colors.fatal ?? "#7d1a1a")(formatLogMessage(message))}
|
|
230259
230259
|
`
|
|
230260
230260
|
);
|
|
230261
230261
|
};
|
|
@@ -230265,7 +230265,7 @@ var getLogFn = (logLevel = LogLevel.INFO, config2 = {}) => {
|
|
|
230265
230265
|
console.error(
|
|
230266
230266
|
`${_chalk.bold.hex(colors.danger ?? "#f85149")(">")} ${_chalk.bold.bgHex(colors.danger ?? "#f85149").whiteBright(
|
|
230267
230267
|
" \u2718 Error "
|
|
230268
|
-
)} ${_chalk.hex(colors.danger ?? "#f85149")(formatLogMessage(message))}
|
|
230268
|
+
)} ${_chalk.hex(colors.danger ?? "#f85149")(formatLogMessage(message))}
|
|
230269
230269
|
`
|
|
230270
230270
|
);
|
|
230271
230271
|
};
|
|
@@ -230275,7 +230275,7 @@ var getLogFn = (logLevel = LogLevel.INFO, config2 = {}) => {
|
|
|
230275
230275
|
console.warn(
|
|
230276
230276
|
`${_chalk.bold.hex(colors.warning ?? "#e3b341")(">")} ${_chalk.bold.bgHex(colors.warning ?? "#e3b341").whiteBright(
|
|
230277
230277
|
" \u26A0 Warn "
|
|
230278
|
-
)} ${_chalk.hex(colors.warning ?? "#e3b341")(formatLogMessage(message))}
|
|
230278
|
+
)} ${_chalk.hex(colors.warning ?? "#e3b341")(formatLogMessage(message))}
|
|
230279
230279
|
`
|
|
230280
230280
|
);
|
|
230281
230281
|
};
|
|
@@ -230285,7 +230285,7 @@ var getLogFn = (logLevel = LogLevel.INFO, config2 = {}) => {
|
|
|
230285
230285
|
console.info(
|
|
230286
230286
|
`${_chalk.bold.hex(colors.success ?? "#56d364")(">")} ${_chalk.bold.bgHex(colors.success ?? "#56d364").whiteBright(
|
|
230287
230287
|
" \u2713 Success "
|
|
230288
|
-
)} ${_chalk.hex(colors.success ?? "#56d364")(formatLogMessage(message))}
|
|
230288
|
+
)} ${_chalk.hex(colors.success ?? "#56d364")(formatLogMessage(message))}
|
|
230289
230289
|
`
|
|
230290
230290
|
);
|
|
230291
230291
|
};
|
|
@@ -230295,17 +230295,17 @@ var getLogFn = (logLevel = LogLevel.INFO, config2 = {}) => {
|
|
|
230295
230295
|
console.info(
|
|
230296
230296
|
`${_chalk.bold.hex(colors.info ?? "#58a6ff")(">")} ${_chalk.bold.bgHex(colors.info ?? "#58a6ff").whiteBright(
|
|
230297
230297
|
" \u2139 Info "
|
|
230298
|
-
)} ${_chalk.hex(colors.info ?? "#58a6ff")(formatLogMessage(message))}
|
|
230298
|
+
)} ${_chalk.hex(colors.info ?? "#58a6ff")(formatLogMessage(message))}
|
|
230299
230299
|
`
|
|
230300
230300
|
);
|
|
230301
230301
|
};
|
|
230302
230302
|
}
|
|
230303
|
-
if (typeof logLevel === "number" && LogLevel.
|
|
230303
|
+
if (typeof logLevel === "number" && LogLevel.TRACE >= logLevel || typeof logLevel === "string" && LogLevel.TRACE >= getLogLevel(logLevel)) {
|
|
230304
230304
|
return (message) => {
|
|
230305
230305
|
console.debug(
|
|
230306
230306
|
`${_chalk.bold.hex(colors.brand ?? "#1fb2a6")(">")} ${_chalk.bold.bgHex(colors.brand ?? "#1fb2a6").whiteBright(
|
|
230307
230307
|
" \u{1F6E0} Debug "
|
|
230308
|
-
)} ${_chalk.hex(colors.brand ?? "#1fb2a6")(formatLogMessage(message))}
|
|
230308
|
+
)} ${_chalk.hex(colors.brand ?? "#1fb2a6")(formatLogMessage(message))}
|
|
230309
230309
|
`
|
|
230310
230310
|
);
|
|
230311
230311
|
};
|
|
@@ -230314,7 +230314,7 @@ var getLogFn = (logLevel = LogLevel.INFO, config2 = {}) => {
|
|
|
230314
230314
|
console.log(
|
|
230315
230315
|
`${_chalk.bold.hex(colors.brand ?? "#1fb2a6")(">")} ${_chalk.bold.bgHex(colors.brand ?? "#1fb2a6").whiteBright(
|
|
230316
230316
|
" \u2709 System "
|
|
230317
|
-
)} ${_chalk.hex(colors.brand ?? "#1fb2a6")(formatLogMessage(message))}
|
|
230317
|
+
)} ${_chalk.hex(colors.brand ?? "#1fb2a6")(formatLogMessage(message))}
|
|
230318
230318
|
`
|
|
230319
230319
|
);
|
|
230320
230320
|
};
|
|
@@ -230326,6 +230326,7 @@ var writeInfo = (message, config2) => getLogFn(LogLevel.INFO, config2)(message);
|
|
|
230326
230326
|
var writeSuccess = (message, config2) => getLogFn(LogLevel.SUCCESS, config2)(message);
|
|
230327
230327
|
var writeDebug = (message, config2) => getLogFn(LogLevel.DEBUG, config2)(message);
|
|
230328
230328
|
var writeTrace = (message, config2) => getLogFn(LogLevel.TRACE, config2)(message);
|
|
230329
|
+
var writeSystem = (message, config2) => getLogFn(LogLevel.ALL, config2)(message);
|
|
230329
230330
|
var MAX_DEPTH = 4;
|
|
230330
230331
|
var formatLogMessage = (message, options8 = {}, depth2 = 0) => {
|
|
230331
230332
|
if (depth2 > MAX_DEPTH) {
|
|
@@ -230406,8 +230407,8 @@ var getConfigFileByName = async (fileName, filePath, options8 = {}) => {
|
|
|
230406
230407
|
name: fileName,
|
|
230407
230408
|
envName: fileName?.toUpperCase(),
|
|
230408
230409
|
jitiOptions: {
|
|
230409
|
-
debug:
|
|
230410
|
-
cache: process.env.
|
|
230410
|
+
debug: false,
|
|
230411
|
+
cache: process.env.STORM_SKIP_CACHE === "true" ? false : process.env.STORM_CACHE_DIRECTORY || "node_modules/.cache/storm"
|
|
230411
230412
|
},
|
|
230412
230413
|
...options8
|
|
230413
230414
|
});
|
|
@@ -230418,8 +230419,8 @@ var getConfigFileByName = async (fileName, filePath, options8 = {}) => {
|
|
|
230418
230419
|
name: fileName,
|
|
230419
230420
|
envName: fileName?.toUpperCase(),
|
|
230420
230421
|
jitiOptions: {
|
|
230421
|
-
debug:
|
|
230422
|
-
cache: process.env.
|
|
230422
|
+
debug: false,
|
|
230423
|
+
cache: process.env.STORM_SKIP_CACHE === "true" ? false : process.env.STORM_CACHE_DIRECTORY || "node_modules/.cache/storm"
|
|
230423
230424
|
},
|
|
230424
230425
|
configFile: fileName,
|
|
230425
230426
|
...options8
|
|
@@ -230432,9 +230433,9 @@ var getConfigFile = async (filePath, additionalFileNames = []) => {
|
|
|
230432
230433
|
const result2 = await getConfigFileByName("storm", workspacePath);
|
|
230433
230434
|
let config2 = result2.config;
|
|
230434
230435
|
const configFile = result2.configFile;
|
|
230435
|
-
if (config2 && Object.keys(config2).length > 0) {
|
|
230436
|
-
|
|
230437
|
-
`Found Storm configuration file "${configFile}" at "${workspacePath}"`,
|
|
230436
|
+
if (config2 && configFile && Object.keys(config2).length > 0) {
|
|
230437
|
+
writeSystem(
|
|
230438
|
+
`Found Storm configuration file "${configFile.includes(`${workspacePath}/`) ? configFile.replace(`${workspacePath}/`, "") : configFile}" at "${workspacePath}"`,
|
|
230438
230439
|
{
|
|
230439
230440
|
logLevel: "all"
|
|
230440
230441
|
}
|
|
@@ -230447,9 +230448,9 @@ var getConfigFile = async (filePath, additionalFileNames = []) => {
|
|
|
230447
230448
|
)
|
|
230448
230449
|
);
|
|
230449
230450
|
for (const result3 of results) {
|
|
230450
|
-
if (result3?.config && Object.keys(result3.config).length > 0) {
|
|
230451
|
-
|
|
230452
|
-
`Found
|
|
230451
|
+
if (result3?.config && result3?.configFile && Object.keys(result3.config).length > 0) {
|
|
230452
|
+
writeSystem(
|
|
230453
|
+
`Found alternative configuration file "${result3.configFile.includes(`${workspacePath}/`) ? result3.configFile.replace(`${workspacePath}/`, "") : result3.configFile}" at "${workspacePath}"`,
|
|
230453
230454
|
{
|
|
230454
230455
|
logLevel: "all"
|
|
230455
230456
|
}
|
package/bin/post-checkout.js
CHANGED
|
@@ -66561,7 +66561,7 @@ var getLogLevelLabel = (logLevel = LogLevel.INFO) => {
|
|
|
66561
66561
|
var getLogFn = (logLevel = LogLevel.INFO, config = {}) => {
|
|
66562
66562
|
const _chalk = getChalk();
|
|
66563
66563
|
const colors = !config.colors?.dark && !config.colors?.["base"] && !config.colors?.["base"]?.dark ? DEFAULT_COLOR_CONFIG : config.colors?.dark && typeof config.colors.dark === "string" ? config.colors : config.colors?.["base"]?.dark && typeof config.colors["base"].dark === "string" ? config.colors["base"].dark : config.colors?.["base"] ? config.colors?.["base"] : DEFAULT_COLOR_CONFIG;
|
|
66564
|
-
const configLogLevel = config.logLevel
|
|
66564
|
+
const configLogLevel = config.logLevel || process.env.STORM_LOG_LEVEL || LogLevelLabel.INFO;
|
|
66565
66565
|
if (typeof logLevel === "number" && (logLevel >= getLogLevel(configLogLevel) || logLevel <= LogLevel.SILENT) || typeof logLevel === "string" && getLogLevel(logLevel) >= getLogLevel(configLogLevel)) {
|
|
66566
66566
|
return (_6) => {
|
|
66567
66567
|
};
|
|
@@ -66569,9 +66569,9 @@ var getLogFn = (logLevel = LogLevel.INFO, config = {}) => {
|
|
|
66569
66569
|
if (typeof logLevel === "number" && LogLevel.FATAL >= logLevel || typeof logLevel === "string" && LogLevel.FATAL >= getLogLevel(logLevel)) {
|
|
66570
66570
|
return (message) => {
|
|
66571
66571
|
console.error(
|
|
66572
|
-
`${_chalk.bold.hex(colors.
|
|
66572
|
+
`${_chalk.bold.hex(colors.fatal ?? "#7d1a1a")(">")} ${_chalk.bold.bgHex(colors.fatal ?? "#7d1a1a").whiteBright(
|
|
66573
66573
|
" \u{1F480} Fatal "
|
|
66574
|
-
)} ${_chalk.hex(colors.
|
|
66574
|
+
)} ${_chalk.hex(colors.fatal ?? "#7d1a1a")(formatLogMessage(message))}
|
|
66575
66575
|
`
|
|
66576
66576
|
);
|
|
66577
66577
|
};
|
|
@@ -66581,7 +66581,7 @@ var getLogFn = (logLevel = LogLevel.INFO, config = {}) => {
|
|
|
66581
66581
|
console.error(
|
|
66582
66582
|
`${_chalk.bold.hex(colors.danger ?? "#f85149")(">")} ${_chalk.bold.bgHex(colors.danger ?? "#f85149").whiteBright(
|
|
66583
66583
|
" \u2718 Error "
|
|
66584
|
-
)} ${_chalk.hex(colors.danger ?? "#f85149")(formatLogMessage(message))}
|
|
66584
|
+
)} ${_chalk.hex(colors.danger ?? "#f85149")(formatLogMessage(message))}
|
|
66585
66585
|
`
|
|
66586
66586
|
);
|
|
66587
66587
|
};
|
|
@@ -66591,7 +66591,7 @@ var getLogFn = (logLevel = LogLevel.INFO, config = {}) => {
|
|
|
66591
66591
|
console.warn(
|
|
66592
66592
|
`${_chalk.bold.hex(colors.warning ?? "#e3b341")(">")} ${_chalk.bold.bgHex(colors.warning ?? "#e3b341").whiteBright(
|
|
66593
66593
|
" \u26A0 Warn "
|
|
66594
|
-
)} ${_chalk.hex(colors.warning ?? "#e3b341")(formatLogMessage(message))}
|
|
66594
|
+
)} ${_chalk.hex(colors.warning ?? "#e3b341")(formatLogMessage(message))}
|
|
66595
66595
|
`
|
|
66596
66596
|
);
|
|
66597
66597
|
};
|
|
@@ -66601,7 +66601,7 @@ var getLogFn = (logLevel = LogLevel.INFO, config = {}) => {
|
|
|
66601
66601
|
console.info(
|
|
66602
66602
|
`${_chalk.bold.hex(colors.success ?? "#56d364")(">")} ${_chalk.bold.bgHex(colors.success ?? "#56d364").whiteBright(
|
|
66603
66603
|
" \u2713 Success "
|
|
66604
|
-
)} ${_chalk.hex(colors.success ?? "#56d364")(formatLogMessage(message))}
|
|
66604
|
+
)} ${_chalk.hex(colors.success ?? "#56d364")(formatLogMessage(message))}
|
|
66605
66605
|
`
|
|
66606
66606
|
);
|
|
66607
66607
|
};
|
|
@@ -66611,17 +66611,17 @@ var getLogFn = (logLevel = LogLevel.INFO, config = {}) => {
|
|
|
66611
66611
|
console.info(
|
|
66612
66612
|
`${_chalk.bold.hex(colors.info ?? "#58a6ff")(">")} ${_chalk.bold.bgHex(colors.info ?? "#58a6ff").whiteBright(
|
|
66613
66613
|
" \u2139 Info "
|
|
66614
|
-
)} ${_chalk.hex(colors.info ?? "#58a6ff")(formatLogMessage(message))}
|
|
66614
|
+
)} ${_chalk.hex(colors.info ?? "#58a6ff")(formatLogMessage(message))}
|
|
66615
66615
|
`
|
|
66616
66616
|
);
|
|
66617
66617
|
};
|
|
66618
66618
|
}
|
|
66619
|
-
if (typeof logLevel === "number" && LogLevel.
|
|
66619
|
+
if (typeof logLevel === "number" && LogLevel.TRACE >= logLevel || typeof logLevel === "string" && LogLevel.TRACE >= getLogLevel(logLevel)) {
|
|
66620
66620
|
return (message) => {
|
|
66621
66621
|
console.debug(
|
|
66622
66622
|
`${_chalk.bold.hex(colors.brand ?? "#1fb2a6")(">")} ${_chalk.bold.bgHex(colors.brand ?? "#1fb2a6").whiteBright(
|
|
66623
66623
|
" \u{1F6E0} Debug "
|
|
66624
|
-
)} ${_chalk.hex(colors.brand ?? "#1fb2a6")(formatLogMessage(message))}
|
|
66624
|
+
)} ${_chalk.hex(colors.brand ?? "#1fb2a6")(formatLogMessage(message))}
|
|
66625
66625
|
`
|
|
66626
66626
|
);
|
|
66627
66627
|
};
|
|
@@ -66630,7 +66630,7 @@ var getLogFn = (logLevel = LogLevel.INFO, config = {}) => {
|
|
|
66630
66630
|
console.log(
|
|
66631
66631
|
`${_chalk.bold.hex(colors.brand ?? "#1fb2a6")(">")} ${_chalk.bold.bgHex(colors.brand ?? "#1fb2a6").whiteBright(
|
|
66632
66632
|
" \u2709 System "
|
|
66633
|
-
)} ${_chalk.hex(colors.brand ?? "#1fb2a6")(formatLogMessage(message))}
|
|
66633
|
+
)} ${_chalk.hex(colors.brand ?? "#1fb2a6")(formatLogMessage(message))}
|
|
66634
66634
|
`
|
|
66635
66635
|
);
|
|
66636
66636
|
};
|
|
@@ -66641,6 +66641,7 @@ var writeWarning = (message, config) => getLogFn(LogLevel.WARN, config)(message)
|
|
|
66641
66641
|
var writeInfo = (message, config) => getLogFn(LogLevel.INFO, config)(message);
|
|
66642
66642
|
var writeSuccess = (message, config) => getLogFn(LogLevel.SUCCESS, config)(message);
|
|
66643
66643
|
var writeTrace = (message, config) => getLogFn(LogLevel.TRACE, config)(message);
|
|
66644
|
+
var writeSystem = (message, config) => getLogFn(LogLevel.ALL, config)(message);
|
|
66644
66645
|
var MAX_DEPTH = 4;
|
|
66645
66646
|
var formatLogMessage = (message, options = {}, depth2 = 0) => {
|
|
66646
66647
|
if (depth2 > MAX_DEPTH) {
|
|
@@ -66737,8 +66738,8 @@ var getConfigFileByName = async (fileName, filePath, options = {}) => {
|
|
|
66737
66738
|
name: fileName,
|
|
66738
66739
|
envName: fileName?.toUpperCase(),
|
|
66739
66740
|
jitiOptions: {
|
|
66740
|
-
debug:
|
|
66741
|
-
cache: process.env.
|
|
66741
|
+
debug: false,
|
|
66742
|
+
cache: process.env.STORM_SKIP_CACHE === "true" ? false : process.env.STORM_CACHE_DIRECTORY || "node_modules/.cache/storm"
|
|
66742
66743
|
},
|
|
66743
66744
|
...options
|
|
66744
66745
|
});
|
|
@@ -66749,8 +66750,8 @@ var getConfigFileByName = async (fileName, filePath, options = {}) => {
|
|
|
66749
66750
|
name: fileName,
|
|
66750
66751
|
envName: fileName?.toUpperCase(),
|
|
66751
66752
|
jitiOptions: {
|
|
66752
|
-
debug:
|
|
66753
|
-
cache: process.env.
|
|
66753
|
+
debug: false,
|
|
66754
|
+
cache: process.env.STORM_SKIP_CACHE === "true" ? false : process.env.STORM_CACHE_DIRECTORY || "node_modules/.cache/storm"
|
|
66754
66755
|
},
|
|
66755
66756
|
configFile: fileName,
|
|
66756
66757
|
...options
|
|
@@ -66763,9 +66764,9 @@ var getConfigFile = async (filePath, additionalFileNames = []) => {
|
|
|
66763
66764
|
const result = await getConfigFileByName("storm", workspacePath);
|
|
66764
66765
|
let config = result.config;
|
|
66765
66766
|
const configFile = result.configFile;
|
|
66766
|
-
if (config && Object.keys(config).length > 0) {
|
|
66767
|
-
|
|
66768
|
-
`Found Storm configuration file "${configFile}" at "${workspacePath}"`,
|
|
66767
|
+
if (config && configFile && Object.keys(config).length > 0) {
|
|
66768
|
+
writeSystem(
|
|
66769
|
+
`Found Storm configuration file "${configFile.includes(`${workspacePath}/`) ? configFile.replace(`${workspacePath}/`, "") : configFile}" at "${workspacePath}"`,
|
|
66769
66770
|
{
|
|
66770
66771
|
logLevel: "all"
|
|
66771
66772
|
}
|
|
@@ -66778,9 +66779,9 @@ var getConfigFile = async (filePath, additionalFileNames = []) => {
|
|
|
66778
66779
|
)
|
|
66779
66780
|
);
|
|
66780
66781
|
for (const result2 of results) {
|
|
66781
|
-
if (result2?.config && Object.keys(result2.config).length > 0) {
|
|
66782
|
-
|
|
66783
|
-
`Found
|
|
66782
|
+
if (result2?.config && result2?.configFile && Object.keys(result2.config).length > 0) {
|
|
66783
|
+
writeSystem(
|
|
66784
|
+
`Found alternative configuration file "${result2.configFile.includes(`${workspacePath}/`) ? result2.configFile.replace(`${workspacePath}/`, "") : result2.configFile}" at "${workspacePath}"`,
|
|
66784
66785
|
{
|
|
66785
66786
|
logLevel: "all"
|
|
66786
66787
|
}
|
package/bin/post-commit.js
CHANGED
|
@@ -66561,7 +66561,7 @@ var getLogLevelLabel = (logLevel = LogLevel.INFO) => {
|
|
|
66561
66561
|
var getLogFn = (logLevel = LogLevel.INFO, config = {}) => {
|
|
66562
66562
|
const _chalk = getChalk();
|
|
66563
66563
|
const colors = !config.colors?.dark && !config.colors?.["base"] && !config.colors?.["base"]?.dark ? DEFAULT_COLOR_CONFIG : config.colors?.dark && typeof config.colors.dark === "string" ? config.colors : config.colors?.["base"]?.dark && typeof config.colors["base"].dark === "string" ? config.colors["base"].dark : config.colors?.["base"] ? config.colors?.["base"] : DEFAULT_COLOR_CONFIG;
|
|
66564
|
-
const configLogLevel = config.logLevel
|
|
66564
|
+
const configLogLevel = config.logLevel || process.env.STORM_LOG_LEVEL || LogLevelLabel.INFO;
|
|
66565
66565
|
if (typeof logLevel === "number" && (logLevel >= getLogLevel(configLogLevel) || logLevel <= LogLevel.SILENT) || typeof logLevel === "string" && getLogLevel(logLevel) >= getLogLevel(configLogLevel)) {
|
|
66566
66566
|
return (_6) => {
|
|
66567
66567
|
};
|
|
@@ -66569,9 +66569,9 @@ var getLogFn = (logLevel = LogLevel.INFO, config = {}) => {
|
|
|
66569
66569
|
if (typeof logLevel === "number" && LogLevel.FATAL >= logLevel || typeof logLevel === "string" && LogLevel.FATAL >= getLogLevel(logLevel)) {
|
|
66570
66570
|
return (message) => {
|
|
66571
66571
|
console.error(
|
|
66572
|
-
`${_chalk.bold.hex(colors.
|
|
66572
|
+
`${_chalk.bold.hex(colors.fatal ?? "#7d1a1a")(">")} ${_chalk.bold.bgHex(colors.fatal ?? "#7d1a1a").whiteBright(
|
|
66573
66573
|
" \u{1F480} Fatal "
|
|
66574
|
-
)} ${_chalk.hex(colors.
|
|
66574
|
+
)} ${_chalk.hex(colors.fatal ?? "#7d1a1a")(formatLogMessage(message))}
|
|
66575
66575
|
`
|
|
66576
66576
|
);
|
|
66577
66577
|
};
|
|
@@ -66581,7 +66581,7 @@ var getLogFn = (logLevel = LogLevel.INFO, config = {}) => {
|
|
|
66581
66581
|
console.error(
|
|
66582
66582
|
`${_chalk.bold.hex(colors.danger ?? "#f85149")(">")} ${_chalk.bold.bgHex(colors.danger ?? "#f85149").whiteBright(
|
|
66583
66583
|
" \u2718 Error "
|
|
66584
|
-
)} ${_chalk.hex(colors.danger ?? "#f85149")(formatLogMessage(message))}
|
|
66584
|
+
)} ${_chalk.hex(colors.danger ?? "#f85149")(formatLogMessage(message))}
|
|
66585
66585
|
`
|
|
66586
66586
|
);
|
|
66587
66587
|
};
|
|
@@ -66591,7 +66591,7 @@ var getLogFn = (logLevel = LogLevel.INFO, config = {}) => {
|
|
|
66591
66591
|
console.warn(
|
|
66592
66592
|
`${_chalk.bold.hex(colors.warning ?? "#e3b341")(">")} ${_chalk.bold.bgHex(colors.warning ?? "#e3b341").whiteBright(
|
|
66593
66593
|
" \u26A0 Warn "
|
|
66594
|
-
)} ${_chalk.hex(colors.warning ?? "#e3b341")(formatLogMessage(message))}
|
|
66594
|
+
)} ${_chalk.hex(colors.warning ?? "#e3b341")(formatLogMessage(message))}
|
|
66595
66595
|
`
|
|
66596
66596
|
);
|
|
66597
66597
|
};
|
|
@@ -66601,7 +66601,7 @@ var getLogFn = (logLevel = LogLevel.INFO, config = {}) => {
|
|
|
66601
66601
|
console.info(
|
|
66602
66602
|
`${_chalk.bold.hex(colors.success ?? "#56d364")(">")} ${_chalk.bold.bgHex(colors.success ?? "#56d364").whiteBright(
|
|
66603
66603
|
" \u2713 Success "
|
|
66604
|
-
)} ${_chalk.hex(colors.success ?? "#56d364")(formatLogMessage(message))}
|
|
66604
|
+
)} ${_chalk.hex(colors.success ?? "#56d364")(formatLogMessage(message))}
|
|
66605
66605
|
`
|
|
66606
66606
|
);
|
|
66607
66607
|
};
|
|
@@ -66611,17 +66611,17 @@ var getLogFn = (logLevel = LogLevel.INFO, config = {}) => {
|
|
|
66611
66611
|
console.info(
|
|
66612
66612
|
`${_chalk.bold.hex(colors.info ?? "#58a6ff")(">")} ${_chalk.bold.bgHex(colors.info ?? "#58a6ff").whiteBright(
|
|
66613
66613
|
" \u2139 Info "
|
|
66614
|
-
)} ${_chalk.hex(colors.info ?? "#58a6ff")(formatLogMessage(message))}
|
|
66614
|
+
)} ${_chalk.hex(colors.info ?? "#58a6ff")(formatLogMessage(message))}
|
|
66615
66615
|
`
|
|
66616
66616
|
);
|
|
66617
66617
|
};
|
|
66618
66618
|
}
|
|
66619
|
-
if (typeof logLevel === "number" && LogLevel.
|
|
66619
|
+
if (typeof logLevel === "number" && LogLevel.TRACE >= logLevel || typeof logLevel === "string" && LogLevel.TRACE >= getLogLevel(logLevel)) {
|
|
66620
66620
|
return (message) => {
|
|
66621
66621
|
console.debug(
|
|
66622
66622
|
`${_chalk.bold.hex(colors.brand ?? "#1fb2a6")(">")} ${_chalk.bold.bgHex(colors.brand ?? "#1fb2a6").whiteBright(
|
|
66623
66623
|
" \u{1F6E0} Debug "
|
|
66624
|
-
)} ${_chalk.hex(colors.brand ?? "#1fb2a6")(formatLogMessage(message))}
|
|
66624
|
+
)} ${_chalk.hex(colors.brand ?? "#1fb2a6")(formatLogMessage(message))}
|
|
66625
66625
|
`
|
|
66626
66626
|
);
|
|
66627
66627
|
};
|
|
@@ -66630,7 +66630,7 @@ var getLogFn = (logLevel = LogLevel.INFO, config = {}) => {
|
|
|
66630
66630
|
console.log(
|
|
66631
66631
|
`${_chalk.bold.hex(colors.brand ?? "#1fb2a6")(">")} ${_chalk.bold.bgHex(colors.brand ?? "#1fb2a6").whiteBright(
|
|
66632
66632
|
" \u2709 System "
|
|
66633
|
-
)} ${_chalk.hex(colors.brand ?? "#1fb2a6")(formatLogMessage(message))}
|
|
66633
|
+
)} ${_chalk.hex(colors.brand ?? "#1fb2a6")(formatLogMessage(message))}
|
|
66634
66634
|
`
|
|
66635
66635
|
);
|
|
66636
66636
|
};
|
|
@@ -66641,6 +66641,7 @@ var writeWarning = (message, config) => getLogFn(LogLevel.WARN, config)(message)
|
|
|
66641
66641
|
var writeInfo = (message, config) => getLogFn(LogLevel.INFO, config)(message);
|
|
66642
66642
|
var writeSuccess = (message, config) => getLogFn(LogLevel.SUCCESS, config)(message);
|
|
66643
66643
|
var writeTrace = (message, config) => getLogFn(LogLevel.TRACE, config)(message);
|
|
66644
|
+
var writeSystem = (message, config) => getLogFn(LogLevel.ALL, config)(message);
|
|
66644
66645
|
var MAX_DEPTH = 4;
|
|
66645
66646
|
var formatLogMessage = (message, options = {}, depth2 = 0) => {
|
|
66646
66647
|
if (depth2 > MAX_DEPTH) {
|
|
@@ -66737,8 +66738,8 @@ var getConfigFileByName = async (fileName, filePath, options = {}) => {
|
|
|
66737
66738
|
name: fileName,
|
|
66738
66739
|
envName: fileName?.toUpperCase(),
|
|
66739
66740
|
jitiOptions: {
|
|
66740
|
-
debug:
|
|
66741
|
-
cache: process.env.
|
|
66741
|
+
debug: false,
|
|
66742
|
+
cache: process.env.STORM_SKIP_CACHE === "true" ? false : process.env.STORM_CACHE_DIRECTORY || "node_modules/.cache/storm"
|
|
66742
66743
|
},
|
|
66743
66744
|
...options
|
|
66744
66745
|
});
|
|
@@ -66749,8 +66750,8 @@ var getConfigFileByName = async (fileName, filePath, options = {}) => {
|
|
|
66749
66750
|
name: fileName,
|
|
66750
66751
|
envName: fileName?.toUpperCase(),
|
|
66751
66752
|
jitiOptions: {
|
|
66752
|
-
debug:
|
|
66753
|
-
cache: process.env.
|
|
66753
|
+
debug: false,
|
|
66754
|
+
cache: process.env.STORM_SKIP_CACHE === "true" ? false : process.env.STORM_CACHE_DIRECTORY || "node_modules/.cache/storm"
|
|
66754
66755
|
},
|
|
66755
66756
|
configFile: fileName,
|
|
66756
66757
|
...options
|
|
@@ -66763,9 +66764,9 @@ var getConfigFile = async (filePath, additionalFileNames = []) => {
|
|
|
66763
66764
|
const result = await getConfigFileByName("storm", workspacePath);
|
|
66764
66765
|
let config = result.config;
|
|
66765
66766
|
const configFile = result.configFile;
|
|
66766
|
-
if (config && Object.keys(config).length > 0) {
|
|
66767
|
-
|
|
66768
|
-
`Found Storm configuration file "${configFile}" at "${workspacePath}"`,
|
|
66767
|
+
if (config && configFile && Object.keys(config).length > 0) {
|
|
66768
|
+
writeSystem(
|
|
66769
|
+
`Found Storm configuration file "${configFile.includes(`${workspacePath}/`) ? configFile.replace(`${workspacePath}/`, "") : configFile}" at "${workspacePath}"`,
|
|
66769
66770
|
{
|
|
66770
66771
|
logLevel: "all"
|
|
66771
66772
|
}
|
|
@@ -66778,9 +66779,9 @@ var getConfigFile = async (filePath, additionalFileNames = []) => {
|
|
|
66778
66779
|
)
|
|
66779
66780
|
);
|
|
66780
66781
|
for (const result2 of results) {
|
|
66781
|
-
if (result2?.config && Object.keys(result2.config).length > 0) {
|
|
66782
|
-
|
|
66783
|
-
`Found
|
|
66782
|
+
if (result2?.config && result2?.configFile && Object.keys(result2.config).length > 0) {
|
|
66783
|
+
writeSystem(
|
|
66784
|
+
`Found alternative configuration file "${result2.configFile.includes(`${workspacePath}/`) ? result2.configFile.replace(`${workspacePath}/`, "") : result2.configFile}" at "${workspacePath}"`,
|
|
66784
66785
|
{
|
|
66785
66786
|
logLevel: "all"
|
|
66786
66787
|
}
|
package/bin/post-merge.js
CHANGED
|
@@ -66561,7 +66561,7 @@ var getLogLevelLabel = (logLevel = LogLevel.INFO) => {
|
|
|
66561
66561
|
var getLogFn = (logLevel = LogLevel.INFO, config = {}) => {
|
|
66562
66562
|
const _chalk = getChalk();
|
|
66563
66563
|
const colors = !config.colors?.dark && !config.colors?.["base"] && !config.colors?.["base"]?.dark ? DEFAULT_COLOR_CONFIG : config.colors?.dark && typeof config.colors.dark === "string" ? config.colors : config.colors?.["base"]?.dark && typeof config.colors["base"].dark === "string" ? config.colors["base"].dark : config.colors?.["base"] ? config.colors?.["base"] : DEFAULT_COLOR_CONFIG;
|
|
66564
|
-
const configLogLevel = config.logLevel
|
|
66564
|
+
const configLogLevel = config.logLevel || process.env.STORM_LOG_LEVEL || LogLevelLabel.INFO;
|
|
66565
66565
|
if (typeof logLevel === "number" && (logLevel >= getLogLevel(configLogLevel) || logLevel <= LogLevel.SILENT) || typeof logLevel === "string" && getLogLevel(logLevel) >= getLogLevel(configLogLevel)) {
|
|
66566
66566
|
return (_6) => {
|
|
66567
66567
|
};
|
|
@@ -66569,9 +66569,9 @@ var getLogFn = (logLevel = LogLevel.INFO, config = {}) => {
|
|
|
66569
66569
|
if (typeof logLevel === "number" && LogLevel.FATAL >= logLevel || typeof logLevel === "string" && LogLevel.FATAL >= getLogLevel(logLevel)) {
|
|
66570
66570
|
return (message) => {
|
|
66571
66571
|
console.error(
|
|
66572
|
-
`${_chalk.bold.hex(colors.
|
|
66572
|
+
`${_chalk.bold.hex(colors.fatal ?? "#7d1a1a")(">")} ${_chalk.bold.bgHex(colors.fatal ?? "#7d1a1a").whiteBright(
|
|
66573
66573
|
" \u{1F480} Fatal "
|
|
66574
|
-
)} ${_chalk.hex(colors.
|
|
66574
|
+
)} ${_chalk.hex(colors.fatal ?? "#7d1a1a")(formatLogMessage(message))}
|
|
66575
66575
|
`
|
|
66576
66576
|
);
|
|
66577
66577
|
};
|
|
@@ -66581,7 +66581,7 @@ var getLogFn = (logLevel = LogLevel.INFO, config = {}) => {
|
|
|
66581
66581
|
console.error(
|
|
66582
66582
|
`${_chalk.bold.hex(colors.danger ?? "#f85149")(">")} ${_chalk.bold.bgHex(colors.danger ?? "#f85149").whiteBright(
|
|
66583
66583
|
" \u2718 Error "
|
|
66584
|
-
)} ${_chalk.hex(colors.danger ?? "#f85149")(formatLogMessage(message))}
|
|
66584
|
+
)} ${_chalk.hex(colors.danger ?? "#f85149")(formatLogMessage(message))}
|
|
66585
66585
|
`
|
|
66586
66586
|
);
|
|
66587
66587
|
};
|
|
@@ -66591,7 +66591,7 @@ var getLogFn = (logLevel = LogLevel.INFO, config = {}) => {
|
|
|
66591
66591
|
console.warn(
|
|
66592
66592
|
`${_chalk.bold.hex(colors.warning ?? "#e3b341")(">")} ${_chalk.bold.bgHex(colors.warning ?? "#e3b341").whiteBright(
|
|
66593
66593
|
" \u26A0 Warn "
|
|
66594
|
-
)} ${_chalk.hex(colors.warning ?? "#e3b341")(formatLogMessage(message))}
|
|
66594
|
+
)} ${_chalk.hex(colors.warning ?? "#e3b341")(formatLogMessage(message))}
|
|
66595
66595
|
`
|
|
66596
66596
|
);
|
|
66597
66597
|
};
|
|
@@ -66601,7 +66601,7 @@ var getLogFn = (logLevel = LogLevel.INFO, config = {}) => {
|
|
|
66601
66601
|
console.info(
|
|
66602
66602
|
`${_chalk.bold.hex(colors.success ?? "#56d364")(">")} ${_chalk.bold.bgHex(colors.success ?? "#56d364").whiteBright(
|
|
66603
66603
|
" \u2713 Success "
|
|
66604
|
-
)} ${_chalk.hex(colors.success ?? "#56d364")(formatLogMessage(message))}
|
|
66604
|
+
)} ${_chalk.hex(colors.success ?? "#56d364")(formatLogMessage(message))}
|
|
66605
66605
|
`
|
|
66606
66606
|
);
|
|
66607
66607
|
};
|
|
@@ -66611,17 +66611,17 @@ var getLogFn = (logLevel = LogLevel.INFO, config = {}) => {
|
|
|
66611
66611
|
console.info(
|
|
66612
66612
|
`${_chalk.bold.hex(colors.info ?? "#58a6ff")(">")} ${_chalk.bold.bgHex(colors.info ?? "#58a6ff").whiteBright(
|
|
66613
66613
|
" \u2139 Info "
|
|
66614
|
-
)} ${_chalk.hex(colors.info ?? "#58a6ff")(formatLogMessage(message))}
|
|
66614
|
+
)} ${_chalk.hex(colors.info ?? "#58a6ff")(formatLogMessage(message))}
|
|
66615
66615
|
`
|
|
66616
66616
|
);
|
|
66617
66617
|
};
|
|
66618
66618
|
}
|
|
66619
|
-
if (typeof logLevel === "number" && LogLevel.
|
|
66619
|
+
if (typeof logLevel === "number" && LogLevel.TRACE >= logLevel || typeof logLevel === "string" && LogLevel.TRACE >= getLogLevel(logLevel)) {
|
|
66620
66620
|
return (message) => {
|
|
66621
66621
|
console.debug(
|
|
66622
66622
|
`${_chalk.bold.hex(colors.brand ?? "#1fb2a6")(">")} ${_chalk.bold.bgHex(colors.brand ?? "#1fb2a6").whiteBright(
|
|
66623
66623
|
" \u{1F6E0} Debug "
|
|
66624
|
-
)} ${_chalk.hex(colors.brand ?? "#1fb2a6")(formatLogMessage(message))}
|
|
66624
|
+
)} ${_chalk.hex(colors.brand ?? "#1fb2a6")(formatLogMessage(message))}
|
|
66625
66625
|
`
|
|
66626
66626
|
);
|
|
66627
66627
|
};
|
|
@@ -66630,7 +66630,7 @@ var getLogFn = (logLevel = LogLevel.INFO, config = {}) => {
|
|
|
66630
66630
|
console.log(
|
|
66631
66631
|
`${_chalk.bold.hex(colors.brand ?? "#1fb2a6")(">")} ${_chalk.bold.bgHex(colors.brand ?? "#1fb2a6").whiteBright(
|
|
66632
66632
|
" \u2709 System "
|
|
66633
|
-
)} ${_chalk.hex(colors.brand ?? "#1fb2a6")(formatLogMessage(message))}
|
|
66633
|
+
)} ${_chalk.hex(colors.brand ?? "#1fb2a6")(formatLogMessage(message))}
|
|
66634
66634
|
`
|
|
66635
66635
|
);
|
|
66636
66636
|
};
|
|
@@ -66641,6 +66641,7 @@ var writeWarning = (message, config) => getLogFn(LogLevel.WARN, config)(message)
|
|
|
66641
66641
|
var writeInfo = (message, config) => getLogFn(LogLevel.INFO, config)(message);
|
|
66642
66642
|
var writeSuccess = (message, config) => getLogFn(LogLevel.SUCCESS, config)(message);
|
|
66643
66643
|
var writeTrace = (message, config) => getLogFn(LogLevel.TRACE, config)(message);
|
|
66644
|
+
var writeSystem = (message, config) => getLogFn(LogLevel.ALL, config)(message);
|
|
66644
66645
|
var MAX_DEPTH = 4;
|
|
66645
66646
|
var formatLogMessage = (message, options = {}, depth2 = 0) => {
|
|
66646
66647
|
if (depth2 > MAX_DEPTH) {
|
|
@@ -66737,8 +66738,8 @@ var getConfigFileByName = async (fileName, filePath, options = {}) => {
|
|
|
66737
66738
|
name: fileName,
|
|
66738
66739
|
envName: fileName?.toUpperCase(),
|
|
66739
66740
|
jitiOptions: {
|
|
66740
|
-
debug:
|
|
66741
|
-
cache: process.env.
|
|
66741
|
+
debug: false,
|
|
66742
|
+
cache: process.env.STORM_SKIP_CACHE === "true" ? false : process.env.STORM_CACHE_DIRECTORY || "node_modules/.cache/storm"
|
|
66742
66743
|
},
|
|
66743
66744
|
...options
|
|
66744
66745
|
});
|
|
@@ -66749,8 +66750,8 @@ var getConfigFileByName = async (fileName, filePath, options = {}) => {
|
|
|
66749
66750
|
name: fileName,
|
|
66750
66751
|
envName: fileName?.toUpperCase(),
|
|
66751
66752
|
jitiOptions: {
|
|
66752
|
-
debug:
|
|
66753
|
-
cache: process.env.
|
|
66753
|
+
debug: false,
|
|
66754
|
+
cache: process.env.STORM_SKIP_CACHE === "true" ? false : process.env.STORM_CACHE_DIRECTORY || "node_modules/.cache/storm"
|
|
66754
66755
|
},
|
|
66755
66756
|
configFile: fileName,
|
|
66756
66757
|
...options
|
|
@@ -66763,9 +66764,9 @@ var getConfigFile = async (filePath, additionalFileNames = []) => {
|
|
|
66763
66764
|
const result = await getConfigFileByName("storm", workspacePath);
|
|
66764
66765
|
let config = result.config;
|
|
66765
66766
|
const configFile = result.configFile;
|
|
66766
|
-
if (config && Object.keys(config).length > 0) {
|
|
66767
|
-
|
|
66768
|
-
`Found Storm configuration file "${configFile}" at "${workspacePath}"`,
|
|
66767
|
+
if (config && configFile && Object.keys(config).length > 0) {
|
|
66768
|
+
writeSystem(
|
|
66769
|
+
`Found Storm configuration file "${configFile.includes(`${workspacePath}/`) ? configFile.replace(`${workspacePath}/`, "") : configFile}" at "${workspacePath}"`,
|
|
66769
66770
|
{
|
|
66770
66771
|
logLevel: "all"
|
|
66771
66772
|
}
|
|
@@ -66778,9 +66779,9 @@ var getConfigFile = async (filePath, additionalFileNames = []) => {
|
|
|
66778
66779
|
)
|
|
66779
66780
|
);
|
|
66780
66781
|
for (const result2 of results) {
|
|
66781
|
-
if (result2?.config && Object.keys(result2.config).length > 0) {
|
|
66782
|
-
|
|
66783
|
-
`Found
|
|
66782
|
+
if (result2?.config && result2?.configFile && Object.keys(result2.config).length > 0) {
|
|
66783
|
+
writeSystem(
|
|
66784
|
+
`Found alternative configuration file "${result2.configFile.includes(`${workspacePath}/`) ? result2.configFile.replace(`${workspacePath}/`, "") : result2.configFile}" at "${workspacePath}"`,
|
|
66784
66785
|
{
|
|
66785
66786
|
logLevel: "all"
|
|
66786
66787
|
}
|