@storm-software/config-tools 1.163.25 → 1.163.26

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.
Files changed (105) hide show
  1. package/README.md +1 -1
  2. package/bin/config.cjs +298 -205
  3. package/bin/config.js +308 -208
  4. package/dist/{chunk-E5AUC34G.cjs → chunk-4JREL2GQ.cjs} +31 -43
  5. package/dist/{chunk-75PQRIWX.js → chunk-4OOVR2GZ.js} +5 -8
  6. package/dist/{chunk-NKHVLY3K.js → chunk-4XRV4CVP.js} +6 -9
  7. package/dist/{chunk-GBY7M6XX.cjs → chunk-56NGBR4S.cjs} +51 -40
  8. package/dist/{chunk-2HSUVM5I.js → chunk-64DXC5WM.js} +4 -8
  9. package/dist/{chunk-7HCO3WBN.cjs → chunk-7BZWQZUV.cjs} +6 -9
  10. package/dist/{chunk-4AM2CTWO.cjs → chunk-7HCUD67D.cjs} +34 -21
  11. package/dist/{chunk-DLO4KL2Z.cjs → chunk-7SIKKF62.cjs} +78 -61
  12. package/dist/{chunk-6LIPH2JW.cjs → chunk-AEZINHEA.cjs} +19 -12
  13. package/dist/{chunk-WZSBZDAU.cjs → chunk-AQ2NOVJF.cjs} +32 -16
  14. package/dist/{chunk-JT77N7TT.js → chunk-BAWQ37NK.js} +13 -12
  15. package/dist/chunk-BJ2W75ZO.cjs +135 -0
  16. package/dist/{chunk-VULQ4N4Z.cjs → chunk-D3TDPGPG.cjs} +6 -9
  17. package/dist/{chunk-SFDIRWJY.js → chunk-ELNIDXR5.js} +20 -14
  18. package/dist/chunk-FCWF3I34.cjs +55 -0
  19. package/dist/{chunk-D6E6GZD2.js → chunk-FRR2ZRWD.js} +30 -42
  20. package/dist/{chunk-YSSMM2WQ.cjs → chunk-GIXUQACB.cjs} +11 -8
  21. package/dist/chunk-H2GU4JMJ.cjs +40 -0
  22. package/dist/{chunk-2LQBYJT5.cjs → chunk-H425P7G5.cjs} +54 -35
  23. package/dist/{chunk-CERDEPKZ.js → chunk-IETV2DPL.js} +32 -16
  24. package/dist/{chunk-ZFRJR2OY.cjs → chunk-J2LCTMCI.cjs} +11 -15
  25. package/dist/{chunk-2V4WR4HU.js → chunk-JX5NLB4S.js} +12 -9
  26. package/dist/chunk-NS5PJ2RM.cjs +32 -0
  27. package/dist/{chunk-FVYBJYYR.js → chunk-OJP4XIBV.js} +2 -5
  28. package/dist/{chunk-OSY5X2AI.cjs → chunk-PLLCZVZO.cjs} +1 -6
  29. package/dist/{chunk-KBPYCUVG.cjs → chunk-PSHJQ2NP.cjs} +2 -5
  30. package/dist/{chunk-OB4WNEXN.js → chunk-QDJMKPQQ.js} +2 -6
  31. package/dist/{chunk-XDS6C7HI.js → chunk-QJUAU656.js} +68 -51
  32. package/dist/chunk-QNDF3RQL.cjs +8 -0
  33. package/dist/{chunk-AWCU6JTS.js → chunk-R6A4VPC4.js} +0 -5
  34. package/dist/{chunk-G2XISPLW.cjs → chunk-RKGXITNB.cjs} +7 -8
  35. package/dist/{chunk-QRKAMMHF.js → chunk-RSKVXFI5.js} +45 -34
  36. package/dist/{chunk-NQFXB5CV.js → chunk-RWBPUJIZ.js} +6 -7
  37. package/dist/chunk-T3MUE32G.js +32 -0
  38. package/dist/{chunk-K6PUXRK3.js → chunk-VLWSWYG7.js} +19 -12
  39. package/dist/{chunk-BC2QD5QZ.js → chunk-WITKEKZ5.js} +50 -33
  40. package/dist/chunk-XEZGYUS2.js +8 -0
  41. package/dist/{chunk-GYFE7GKG.js → chunk-XO6ICAFH.js} +32 -19
  42. package/dist/{chunk-ETZGNPAA.js → chunk-XS7LVKAI.js} +46 -27
  43. package/dist/{chunk-CHA6766N.cjs → chunk-ZGLOKOL3.cjs} +5 -9
  44. package/dist/config-file/get-config-file.cjs +16 -17
  45. package/dist/config-file/get-config-file.js +15 -16
  46. package/dist/config-file/index.cjs +16 -17
  47. package/dist/config-file/index.js +15 -16
  48. package/dist/create-storm-config.cjs +19 -20
  49. package/dist/create-storm-config.js +18 -19
  50. package/dist/env/get-env.cjs +4 -5
  51. package/dist/env/get-env.js +3 -4
  52. package/dist/env/index.cjs +5 -6
  53. package/dist/env/index.js +4 -5
  54. package/dist/env/set-env.cjs +4 -5
  55. package/dist/env/set-env.js +3 -4
  56. package/dist/get-config.cjs +20 -21
  57. package/dist/get-config.js +19 -20
  58. package/dist/index.cjs +21 -22
  59. package/dist/index.js +20 -21
  60. package/dist/logger/chalk.cjs +2 -3
  61. package/dist/logger/chalk.js +1 -2
  62. package/dist/logger/console-icons.cjs +3 -4
  63. package/dist/logger/console-icons.js +2 -3
  64. package/dist/logger/console.cjs +11 -12
  65. package/dist/logger/console.js +10 -11
  66. package/dist/logger/create-logger.cjs +12 -13
  67. package/dist/logger/create-logger.js +11 -12
  68. package/dist/logger/format-timestamp.cjs +2 -3
  69. package/dist/logger/format-timestamp.js +1 -2
  70. package/dist/logger/get-log-level.cjs +2 -3
  71. package/dist/logger/get-log-level.js +1 -2
  72. package/dist/logger/index.cjs +12 -13
  73. package/dist/logger/index.js +11 -12
  74. package/dist/logger/is-unicode-supported.cjs +2 -3
  75. package/dist/logger/is-unicode-supported.js +1 -2
  76. package/dist/types.cjs +0 -1
  77. package/dist/types.js +0 -1
  78. package/dist/utilities/apply-workspace-tokens.cjs +5 -6
  79. package/dist/utilities/apply-workspace-tokens.js +4 -5
  80. package/dist/utilities/correct-paths.cjs +2 -3
  81. package/dist/utilities/correct-paths.js +1 -2
  82. package/dist/utilities/file-path-utils.cjs +2 -3
  83. package/dist/utilities/file-path-utils.js +1 -2
  84. package/dist/utilities/find-up.cjs +2 -3
  85. package/dist/utilities/find-up.js +1 -2
  86. package/dist/utilities/find-workspace-root.cjs +4 -5
  87. package/dist/utilities/find-workspace-root.js +3 -4
  88. package/dist/utilities/get-default-config.cjs +5 -6
  89. package/dist/utilities/get-default-config.js +4 -5
  90. package/dist/utilities/index.cjs +15 -16
  91. package/dist/utilities/index.js +14 -15
  92. package/dist/utilities/process-handler.cjs +12 -13
  93. package/dist/utilities/process-handler.js +11 -12
  94. package/dist/utilities/run.cjs +2 -3
  95. package/dist/utilities/run.js +1 -2
  96. package/package.json +1 -1
  97. package/dist/chunk-7DEX73IB.js +0 -36
  98. package/dist/chunk-HFKBN5GE.cjs +0 -118
  99. package/dist/chunk-IGUYFX5B.cjs +0 -12
  100. package/dist/chunk-SHUYVCID.js +0 -6
  101. package/dist/chunk-SIU3CSEY.cjs +0 -49
  102. package/dist/chunk-TKQCRNGC.js +0 -12
  103. package/dist/chunk-USNT2KNT.cjs +0 -6
  104. package/dist/chunk-VICC23NV.cjs +0 -36
  105. package/dist/chunk-VKTQOXWO.cjs +0 -39
@@ -1,8 +1,4 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }
2
-
3
- var _chunkUSNT2KNTcjs = require('./chunk-USNT2KNT.cjs');
4
-
5
- // src/utilities/correct-paths.ts
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }// src/utilities/correct-paths.ts
6
2
  var _DRIVE_LETTER_START_RE = /^[A-Za-z]:\//;
7
3
  function normalizeWindowsPath(input = "") {
8
4
  if (!input) {
@@ -10,7 +6,6 @@ function normalizeWindowsPath(input = "") {
10
6
  }
11
7
  return input.replace(/\\/g, "/").replace(_DRIVE_LETTER_START_RE, (r) => r.toUpperCase());
12
8
  }
13
- _chunkUSNT2KNTcjs.__name.call(void 0, normalizeWindowsPath, "normalizeWindowsPath");
14
9
  var _UNC_REGEX = /^[/\\]{2}/;
15
10
  var _IS_ABSOLUTE_RE = /^[/\\](?![/\\])|^[/\\]{2}(?!\.)|^[A-Za-z]:[/\\]/;
16
11
  var _DRIVE_LETTER_RE = /^[A-Za-z]:$/;
@@ -18,7 +13,7 @@ var _ROOT_FOLDER_RE = /^\/([A-Za-z]:)?$/;
18
13
  var _EXTNAME_RE = /.(\.[^./]+|\.)$/;
19
14
  var _PATH_ROOT_RE = /^[/\\]|^[a-zA-Z]:[/\\]/;
20
15
  var sep = "/";
21
- var correctPaths = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, function(path) {
16
+ var correctPaths = function(path) {
22
17
  if (!path || path.length === 0) {
23
18
  return ".";
24
19
  }
@@ -46,8 +41,8 @@ var correctPaths = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, functio
46
41
  return `//${path}`;
47
42
  }
48
43
  return isPathAbsolute && !isAbsolute(path) ? `/${path}` : path;
49
- }, "correctPaths");
50
- var joinPaths = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, function(...segments) {
44
+ };
45
+ var joinPaths = function(...segments) {
51
46
  let path = "";
52
47
  for (const seg of segments) {
53
48
  if (!seg) {
@@ -67,15 +62,14 @@ var joinPaths = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, function(.
67
62
  }
68
63
  }
69
64
  return correctPaths(path);
70
- }, "joinPaths");
65
+ };
71
66
  function cwd() {
72
67
  if (typeof process !== "undefined" && typeof process.cwd === "function") {
73
68
  return process.cwd().replace(/\\/g, "/");
74
69
  }
75
70
  return "/";
76
71
  }
77
- _chunkUSNT2KNTcjs.__name.call(void 0, cwd, "cwd");
78
- var resolve = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, function(...arguments_) {
72
+ var resolve = function(...arguments_) {
79
73
  arguments_ = arguments_.map((argument) => normalizeWindowsPath(argument));
80
74
  let resolvedPath = "";
81
75
  let resolvedAbsolute = false;
@@ -92,7 +86,7 @@ var resolve = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, function(...
92
86
  return `/${resolvedPath}`;
93
87
  }
94
88
  return resolvedPath.length > 0 ? resolvedPath : ".";
95
- }, "resolve");
89
+ };
96
90
  function normalizeString(path, allowAboveRoot) {
97
91
  let res = "";
98
92
  let lastSegmentLength = 0;
@@ -153,27 +147,24 @@ function normalizeString(path, allowAboveRoot) {
153
147
  }
154
148
  return res;
155
149
  }
156
- _chunkUSNT2KNTcjs.__name.call(void 0, normalizeString, "normalizeString");
157
- var isAbsolute = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, function(p) {
150
+ var isAbsolute = function(p) {
158
151
  return _IS_ABSOLUTE_RE.test(p);
159
- }, "isAbsolute");
160
- var toNamespacedPath = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, function(p) {
152
+ };
153
+ var toNamespacedPath = function(p) {
161
154
  return normalizeWindowsPath(p);
162
- }, "toNamespacedPath");
163
- var extname = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, function(p) {
155
+ };
156
+ var extname = function(p) {
164
157
  if (p === "..") return "";
165
158
  const match = _EXTNAME_RE.exec(normalizeWindowsPath(p));
166
159
  return match && match[1] || "";
167
- }, "extname");
168
- var relative = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, function(from, to) {
160
+ };
161
+ var relative = function(from, to) {
169
162
  const _from = resolve(from).replace(_ROOT_FOLDER_RE, "$1").split("/");
170
163
  const _to = resolve(to).replace(_ROOT_FOLDER_RE, "$1").split("/");
171
164
  if (_to[0][1] === ":" && _from[0][1] === ":" && _from[0] !== _to[0]) {
172
165
  return _to.join("/");
173
166
  }
174
- const _fromCopy = [
175
- ..._from
176
- ];
167
+ const _fromCopy = [..._from];
177
168
  for (const segment of _fromCopy) {
178
169
  if (_to[0] !== segment) {
179
170
  break;
@@ -181,28 +172,25 @@ var relative = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, function(fr
181
172
  _from.shift();
182
173
  _to.shift();
183
174
  }
184
- return [
185
- ..._from.map(() => ".."),
186
- ..._to
187
- ].join("/");
188
- }, "relative");
189
- var dirname = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, function(p) {
175
+ return [..._from.map(() => ".."), ..._to].join("/");
176
+ };
177
+ var dirname = function(p) {
190
178
  const segments = normalizeWindowsPath(p).replace(/\/$/, "").split("/").slice(0, -1);
191
179
  if (segments.length === 1 && _DRIVE_LETTER_RE.test(segments[0])) {
192
180
  segments[0] += "/";
193
181
  }
194
182
  return segments.join("/") || (isAbsolute(p) ? "/" : ".");
195
- }, "dirname");
196
- var format = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, function(p) {
183
+ };
184
+ var format = function(p) {
197
185
  const ext = p.ext ? p.ext.startsWith(".") ? p.ext : `.${p.ext}` : "";
198
- const segments = [
199
- p.root,
200
- p.dir,
201
- _nullishCoalesce(p.base, () => ( (_nullishCoalesce(p.name, () => ( ""))) + ext))
202
- ].filter(Boolean);
203
- return normalizeWindowsPath(p.root ? resolve(...segments) : segments.join("/"));
204
- }, "format");
205
- var basename = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, function(p, extension) {
186
+ const segments = [p.root, p.dir, _nullishCoalesce(p.base, () => ( (_nullishCoalesce(p.name, () => ( ""))) + ext))].filter(
187
+ Boolean
188
+ );
189
+ return normalizeWindowsPath(
190
+ p.root ? resolve(...segments) : segments.join("/")
191
+ );
192
+ };
193
+ var basename = function(p, extension) {
206
194
  const segments = normalizeWindowsPath(p).split("/");
207
195
  let lastSegment = "";
208
196
  for (let i = segments.length - 1; i >= 0; i--) {
@@ -213,8 +201,8 @@ var basename = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, function(p,
213
201
  }
214
202
  }
215
203
  return extension && lastSegment.endsWith(extension) ? lastSegment.slice(0, -extension.length) : lastSegment;
216
- }, "basename");
217
- var parse = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, function(p) {
204
+ };
205
+ var parse = function(p) {
218
206
  const root = _optionalChain([_PATH_ROOT_RE, 'access', _ => _.exec, 'call', _2 => _2(p), 'optionalAccess', _3 => _3[0], 'optionalAccess', _4 => _4.replace, 'call', _5 => _5(/\\/g, "/")]) || "";
219
207
  const base = basename(p);
220
208
  const extension = extname(base);
@@ -225,7 +213,7 @@ var parse = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, function(p) {
225
213
  ext: extension,
226
214
  name: base.slice(0, base.length - extension.length)
227
215
  };
228
- }, "parse");
216
+ };
229
217
 
230
218
 
231
219
 
@@ -1,10 +1,6 @@
1
- import {
2
- __name
3
- } from "./chunk-SHUYVCID.js";
4
-
5
1
  // src/utilities/file-path-utils.ts
6
2
  import { sep } from "node:path";
7
- var removeExtension = /* @__PURE__ */ __name((filePath) => {
3
+ var removeExtension = (filePath) => {
8
4
  const result = !filePath || (filePath.match(/./g) || []).length <= 1 ? "." : filePath.lastIndexOf(".") ? filePath.substring(0, filePath.lastIndexOf(".")) : filePath;
9
5
  if (result.startsWith("./")) {
10
6
  return result.substring(2);
@@ -13,11 +9,12 @@ var removeExtension = /* @__PURE__ */ __name((filePath) => {
13
9
  return result.substring(1);
14
10
  }
15
11
  return result;
16
- }, "removeExtension");
12
+ };
17
13
  function findFileName(filePath) {
18
- return filePath?.split(filePath?.includes(sep) ? sep : filePath?.includes("/") ? "/" : "\\")?.pop() ?? "";
14
+ return filePath?.split(
15
+ filePath?.includes(sep) ? sep : filePath?.includes("/") ? "/" : "\\"
16
+ )?.pop() ?? "";
19
17
  }
20
- __name(findFileName, "findFileName");
21
18
 
22
19
  export {
23
20
  removeExtension,
@@ -2,12 +2,9 @@ import {
2
2
  LogLevel,
3
3
  LogLevelLabel
4
4
  } from "./chunk-3QAWRU2B.js";
5
- import {
6
- __name
7
- } from "./chunk-SHUYVCID.js";
8
5
 
9
6
  // src/logger/get-log-level.ts
10
- var getLogLevel = /* @__PURE__ */ __name((label) => {
7
+ var getLogLevel = (label) => {
11
8
  switch (label) {
12
9
  case "all":
13
10
  return LogLevel.ALL;
@@ -28,8 +25,8 @@ var getLogLevel = /* @__PURE__ */ __name((label) => {
28
25
  default:
29
26
  return LogLevel.INFO;
30
27
  }
31
- }, "getLogLevel");
32
- var getLogLevelLabel = /* @__PURE__ */ __name((logLevel = LogLevel.INFO) => {
28
+ };
29
+ var getLogLevelLabel = (logLevel = LogLevel.INFO) => {
33
30
  if (logLevel >= LogLevel.ALL) {
34
31
  return LogLevelLabel.ALL;
35
32
  }
@@ -55,11 +52,11 @@ var getLogLevelLabel = /* @__PURE__ */ __name((logLevel = LogLevel.INFO) => {
55
52
  return LogLevelLabel.SILENT;
56
53
  }
57
54
  return LogLevelLabel.INFO;
58
- }, "getLogLevelLabel");
59
- var isVerbose = /* @__PURE__ */ __name((label = LogLevelLabel.SILENT) => {
55
+ };
56
+ var isVerbose = (label = LogLevelLabel.SILENT) => {
60
57
  const logLevel = typeof label === "string" ? getLogLevel(label) : label;
61
58
  return logLevel >= LogLevel.DEBUG;
62
- }, "isVerbose");
59
+ };
63
60
 
64
61
  export {
65
62
  getLogLevel,
@@ -1,26 +1,30 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } }
2
2
 
3
- var _chunkE5AUC34Gcjs = require('./chunk-E5AUC34G.cjs');
3
+ var _chunk4JREL2GQcjs = require('./chunk-4JREL2GQ.cjs');
4
+
5
+
6
+ var _chunk7BZWQZUVcjs = require('./chunk-7BZWQZUV.cjs');
7
+
8
+ // src/env/get-env.ts
4
9
 
5
10
 
6
- var _chunk7HCO3WBNcjs = require('./chunk-7HCO3WBN.cjs');
7
11
 
8
12
 
9
- var _chunkUSNT2KNTcjs = require('./chunk-USNT2KNT.cjs');
10
13
 
11
- // src/env/get-env.ts
12
14
  var _config = require('@storm-software/config');
13
- var getExtensionEnv = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, (extensionName) => {
15
+ var getExtensionEnv = (extensionName) => {
14
16
  const prefix = `STORM_EXTENSION_${extensionName.toUpperCase()}_`;
15
17
  return Object.keys(process.env).filter((key) => key.startsWith(prefix)).reduce((ret, key) => {
16
- const name = key.replace(prefix, "").split("_").map((i) => i.length > 0 ? i.trim().charAt(0).toUpperCase() + i.trim().slice(1) : "").join("");
18
+ const name = key.replace(prefix, "").split("_").map(
19
+ (i) => i.length > 0 ? i.trim().charAt(0).toUpperCase() + i.trim().slice(1) : ""
20
+ ).join("");
17
21
  if (name) {
18
22
  ret[name] = process.env[key];
19
23
  }
20
24
  return ret;
21
25
  }, {});
22
- }, "getExtensionEnv");
23
- var getConfigEnv = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, () => {
26
+ };
27
+ var getConfigEnv = () => {
24
28
  const prefix = "STORM_";
25
29
  let config = {
26
30
  extends: process.env[`${prefix}EXTENDS`] || void 0,
@@ -57,15 +61,15 @@ var getConfigEnv = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, () => {
57
61
  contact: process.env[`${prefix}CONTACT`] || void 0,
58
62
  timezone: process.env[`${prefix}TIMEZONE`] || process.env.TZ || void 0,
59
63
  locale: process.env[`${prefix}LOCALE`] || process.env.LOCALE || void 0,
60
- configFile: process.env[`${prefix}CONFIG_FILE`] ? _chunkE5AUC34Gcjs.correctPaths.call(void 0, process.env[`${prefix}CONFIG_FILE`]) : void 0,
61
- workspaceRoot: process.env[`${prefix}WORKSPACE_ROOT`] ? _chunkE5AUC34Gcjs.correctPaths.call(void 0, process.env[`${prefix}WORKSPACE_ROOT`]) : void 0,
64
+ configFile: process.env[`${prefix}CONFIG_FILE`] ? _chunk4JREL2GQcjs.correctPaths.call(void 0, process.env[`${prefix}CONFIG_FILE`]) : void 0,
65
+ workspaceRoot: process.env[`${prefix}WORKSPACE_ROOT`] ? _chunk4JREL2GQcjs.correctPaths.call(void 0, process.env[`${prefix}WORKSPACE_ROOT`]) : void 0,
62
66
  directories: {
63
- cache: process.env[`${prefix}CACHE_DIR`] ? _chunkE5AUC34Gcjs.correctPaths.call(void 0, process.env[`${prefix}CACHE_DIR`]) : process.env[`${prefix}CACHE_DIRECTORY`] ? _chunkE5AUC34Gcjs.correctPaths.call(void 0, process.env[`${prefix}CACHE_DIRECTORY`]) : void 0,
64
- data: process.env[`${prefix}DATA_DIR`] ? _chunkE5AUC34Gcjs.correctPaths.call(void 0, process.env[`${prefix}DATA_DIR`]) : process.env[`${prefix}DATA_DIRECTORY`] ? _chunkE5AUC34Gcjs.correctPaths.call(void 0, process.env[`${prefix}DATA_DIRECTORY`]) : void 0,
65
- config: process.env[`${prefix}CONFIG_DIR`] ? _chunkE5AUC34Gcjs.correctPaths.call(void 0, process.env[`${prefix}CONFIG_DIR`]) : process.env[`${prefix}CONFIG_DIRECTORY`] ? _chunkE5AUC34Gcjs.correctPaths.call(void 0, process.env[`${prefix}CONFIG_DIRECTORY`]) : void 0,
66
- temp: process.env[`${prefix}TEMP_DIR`] ? _chunkE5AUC34Gcjs.correctPaths.call(void 0, process.env[`${prefix}TEMP_DIR`]) : process.env[`${prefix}TEMP_DIRECTORY`] ? _chunkE5AUC34Gcjs.correctPaths.call(void 0, process.env[`${prefix}TEMP_DIRECTORY`]) : void 0,
67
- log: process.env[`${prefix}LOG_DIR`] ? _chunkE5AUC34Gcjs.correctPaths.call(void 0, process.env[`${prefix}LOG_DIR`]) : process.env[`${prefix}LOG_DIRECTORY`] ? _chunkE5AUC34Gcjs.correctPaths.call(void 0, process.env[`${prefix}LOG_DIRECTORY`]) : void 0,
68
- build: process.env[`${prefix}BUILD_DIR`] ? _chunkE5AUC34Gcjs.correctPaths.call(void 0, process.env[`${prefix}BUILD_DIR`]) : process.env[`${prefix}BUILD_DIRECTORY`] ? _chunkE5AUC34Gcjs.correctPaths.call(void 0, process.env[`${prefix}BUILD_DIRECTORY`]) : void 0
67
+ cache: process.env[`${prefix}CACHE_DIR`] ? _chunk4JREL2GQcjs.correctPaths.call(void 0, process.env[`${prefix}CACHE_DIR`]) : process.env[`${prefix}CACHE_DIRECTORY`] ? _chunk4JREL2GQcjs.correctPaths.call(void 0, process.env[`${prefix}CACHE_DIRECTORY`]) : void 0,
68
+ data: process.env[`${prefix}DATA_DIR`] ? _chunk4JREL2GQcjs.correctPaths.call(void 0, process.env[`${prefix}DATA_DIR`]) : process.env[`${prefix}DATA_DIRECTORY`] ? _chunk4JREL2GQcjs.correctPaths.call(void 0, process.env[`${prefix}DATA_DIRECTORY`]) : void 0,
69
+ config: process.env[`${prefix}CONFIG_DIR`] ? _chunk4JREL2GQcjs.correctPaths.call(void 0, process.env[`${prefix}CONFIG_DIR`]) : process.env[`${prefix}CONFIG_DIRECTORY`] ? _chunk4JREL2GQcjs.correctPaths.call(void 0, process.env[`${prefix}CONFIG_DIRECTORY`]) : void 0,
70
+ temp: process.env[`${prefix}TEMP_DIR`] ? _chunk4JREL2GQcjs.correctPaths.call(void 0, process.env[`${prefix}TEMP_DIR`]) : process.env[`${prefix}TEMP_DIRECTORY`] ? _chunk4JREL2GQcjs.correctPaths.call(void 0, process.env[`${prefix}TEMP_DIRECTORY`]) : void 0,
71
+ log: process.env[`${prefix}LOG_DIR`] ? _chunk4JREL2GQcjs.correctPaths.call(void 0, process.env[`${prefix}LOG_DIR`]) : process.env[`${prefix}LOG_DIRECTORY`] ? _chunk4JREL2GQcjs.correctPaths.call(void 0, process.env[`${prefix}LOG_DIRECTORY`]) : void 0,
72
+ build: process.env[`${prefix}BUILD_DIR`] ? _chunk4JREL2GQcjs.correctPaths.call(void 0, process.env[`${prefix}BUILD_DIR`]) : process.env[`${prefix}BUILD_DIRECTORY`] ? _chunk4JREL2GQcjs.correctPaths.call(void 0, process.env[`${prefix}BUILD_DIRECTORY`]) : void 0
69
73
  },
70
74
  skipCache: process.env[`${prefix}SKIP_CACHE`] !== void 0 ? Boolean(process.env[`${prefix}SKIP_CACHE`]) : void 0,
71
75
  mode: (_nullishCoalesce(_nullishCoalesce(process.env[`${prefix}MODE`], () => ( process.env.NODE_ENV)), () => ( process.env.ENVIRONMENT))) || void 0,
@@ -88,14 +92,25 @@ var getConfigEnv = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, () => {
88
92
  cyclone: process.env[`${prefix}REGISTRY_CYCLONE`] || void 0,
89
93
  container: process.env[`${prefix}REGISTRY_CONTAINER`] || void 0
90
94
  },
91
- logLevel: process.env[`${prefix}LOG_LEVEL`] !== null && process.env[`${prefix}LOG_LEVEL`] !== void 0 ? process.env[`${prefix}LOG_LEVEL`] && Number.isSafeInteger(Number.parseInt(process.env[`${prefix}LOG_LEVEL`])) ? _chunk7HCO3WBNcjs.getLogLevelLabel.call(void 0, Number.parseInt(process.env[`${prefix}LOG_LEVEL`])) : process.env[`${prefix}LOG_LEVEL`] : void 0,
95
+ logLevel: process.env[`${prefix}LOG_LEVEL`] !== null && process.env[`${prefix}LOG_LEVEL`] !== void 0 ? process.env[`${prefix}LOG_LEVEL`] && Number.isSafeInteger(
96
+ Number.parseInt(process.env[`${prefix}LOG_LEVEL`])
97
+ ) ? _chunk7BZWQZUVcjs.getLogLevelLabel.call(void 0,
98
+ Number.parseInt(process.env[`${prefix}LOG_LEVEL`])
99
+ ) : process.env[`${prefix}LOG_LEVEL`] : void 0,
92
100
  skipConfigLogging: process.env[`${prefix}SKIP_CONFIG_LOGGING`] !== void 0 ? Boolean(process.env[`${prefix}SKIP_CONFIG_LOGGING`]) : void 0
93
101
  };
94
- const themeNames = Object.keys(process.env).filter((envKey) => envKey.startsWith(`${prefix}COLOR_`) && _config.COLOR_KEYS.every((colorKey) => !envKey.startsWith(`${prefix}COLOR_LIGHT_${colorKey}`) && !envKey.startsWith(`${prefix}COLOR_DARK_${colorKey}`)));
95
- config.colors = themeNames.length > 0 ? themeNames.reduce((ret, themeName) => {
96
- ret[themeName] = getThemeColorConfigEnv(prefix, themeName);
97
- return ret;
98
- }, {}) : getThemeColorConfigEnv(prefix);
102
+ const themeNames = Object.keys(process.env).filter(
103
+ (envKey) => envKey.startsWith(`${prefix}COLOR_`) && _config.COLOR_KEYS.every(
104
+ (colorKey) => !envKey.startsWith(`${prefix}COLOR_LIGHT_${colorKey}`) && !envKey.startsWith(`${prefix}COLOR_DARK_${colorKey}`)
105
+ )
106
+ );
107
+ config.colors = themeNames.length > 0 ? themeNames.reduce(
108
+ (ret, themeName) => {
109
+ ret[themeName] = getThemeColorConfigEnv(prefix, themeName);
110
+ return ret;
111
+ },
112
+ {}
113
+ ) : getThemeColorConfigEnv(prefix);
99
114
  if (config.docs === _config.STORM_DEFAULT_DOCS) {
100
115
  if (config.homepage === _config.STORM_DEFAULT_HOMEPAGE) {
101
116
  config.docs = `${_config.STORM_DEFAULT_HOMEPAGE}/projects/${config.name}/docs`;
@@ -116,23 +131,17 @@ var getConfigEnv = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, () => {
116
131
  config = {
117
132
  ...config,
118
133
  ...parsed,
119
- colors: {
120
- ...config.colors,
121
- ...parsed.colors
122
- },
123
- extensions: {
124
- ...config.extensions,
125
- ...parsed.extensions
126
- }
134
+ colors: { ...config.colors, ...parsed.colors },
135
+ extensions: { ...config.extensions, ...parsed.extensions }
127
136
  };
128
137
  }
129
138
  return config;
130
- }, "getConfigEnv");
131
- var getThemeColorConfigEnv = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, (prefix, theme) => {
139
+ };
140
+ var getThemeColorConfigEnv = (prefix, theme) => {
132
141
  const themeName = `COLOR_${theme && theme !== "base" ? `${theme}_` : ""}`.toUpperCase();
133
142
  return process.env[`${prefix}${themeName}LIGHT_BRAND`] || process.env[`${prefix}${themeName}DARK_BRAND`] ? getMultiThemeColorConfigEnv(prefix + themeName) : getSingleThemeColorConfigEnv(prefix + themeName);
134
- }, "getThemeColorConfigEnv");
135
- var getSingleThemeColorConfigEnv = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, (prefix) => {
143
+ };
144
+ var getSingleThemeColorConfigEnv = (prefix) => {
136
145
  return {
137
146
  dark: process.env[`${prefix}DARK`],
138
147
  light: process.env[`${prefix}LIGHT`],
@@ -149,14 +158,16 @@ var getSingleThemeColorConfigEnv = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call
149
158
  positive: process.env[`${prefix}POSITIVE`],
150
159
  negative: process.env[`${prefix}NEGATIVE`]
151
160
  };
152
- }, "getSingleThemeColorConfigEnv");
153
- var getMultiThemeColorConfigEnv = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, (prefix) => {
161
+ };
162
+ var getMultiThemeColorConfigEnv = (prefix) => {
154
163
  return {
155
- light: getBaseThemeColorConfigEnv(`${prefix}_LIGHT_`),
164
+ light: getBaseThemeColorConfigEnv(
165
+ `${prefix}_LIGHT_`
166
+ ),
156
167
  dark: getBaseThemeColorConfigEnv(`${prefix}_DARK_`)
157
168
  };
158
- }, "getMultiThemeColorConfigEnv");
159
- var getBaseThemeColorConfigEnv = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, (prefix) => {
169
+ };
170
+ var getBaseThemeColorConfigEnv = (prefix) => {
160
171
  return {
161
172
  foreground: process.env[`${prefix}FOREGROUND`],
162
173
  background: process.env[`${prefix}BACKGROUND`],
@@ -173,7 +184,7 @@ var getBaseThemeColorConfigEnv = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(v
173
184
  positive: process.env[`${prefix}POSITIVE`],
174
185
  negative: process.env[`${prefix}NEGATIVE`]
175
186
  };
176
- }, "getBaseThemeColorConfigEnv");
187
+ };
177
188
 
178
189
 
179
190
 
@@ -1,11 +1,7 @@
1
- import {
2
- __name
3
- } from "./chunk-SHUYVCID.js";
4
-
5
1
  // src/utilities/run.ts
6
2
  import { exec, execSync } from "node:child_process";
7
3
  var LARGE_BUFFER = 1024 * 1e6;
8
- var run = /* @__PURE__ */ __name((config, command, cwd = config.workspaceRoot ?? process.cwd(), stdio = "inherit", env = process.env) => {
4
+ var run = (config, command, cwd = config.workspaceRoot ?? process.cwd(), stdio = "inherit", env = process.env) => {
9
5
  return execSync(command, {
10
6
  cwd,
11
7
  env: {
@@ -19,8 +15,8 @@ var run = /* @__PURE__ */ __name((config, command, cwd = config.workspaceRoot ??
19
15
  maxBuffer: LARGE_BUFFER,
20
16
  killSignal: "SIGTERM"
21
17
  });
22
- }, "run");
23
- var runAsync = /* @__PURE__ */ __name((config, command, cwd = config.workspaceRoot ?? process.cwd(), env = process.env) => {
18
+ };
19
+ var runAsync = (config, command, cwd = config.workspaceRoot ?? process.cwd(), env = process.env) => {
24
20
  return exec(command, {
25
21
  cwd,
26
22
  env: {
@@ -33,7 +29,7 @@ var runAsync = /* @__PURE__ */ __name((config, command, cwd = config.workspaceRo
33
29
  maxBuffer: LARGE_BUFFER,
34
30
  killSignal: "SIGTERM"
35
31
  });
36
- }, "runAsync");
32
+ };
37
33
 
38
34
  export {
39
35
  LARGE_BUFFER,
@@ -3,11 +3,8 @@
3
3
 
4
4
  var _chunkC5OTFOQBcjs = require('./chunk-C5OTFOQB.cjs');
5
5
 
6
-
7
- var _chunkUSNT2KNTcjs = require('./chunk-USNT2KNT.cjs');
8
-
9
6
  // src/logger/get-log-level.ts
10
- var getLogLevel = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, (label) => {
7
+ var getLogLevel = (label) => {
11
8
  switch (label) {
12
9
  case "all":
13
10
  return _chunkC5OTFOQBcjs.LogLevel.ALL;
@@ -28,8 +25,8 @@ var getLogLevel = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, (label)
28
25
  default:
29
26
  return _chunkC5OTFOQBcjs.LogLevel.INFO;
30
27
  }
31
- }, "getLogLevel");
32
- var getLogLevelLabel = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, (logLevel = _chunkC5OTFOQBcjs.LogLevel.INFO) => {
28
+ };
29
+ var getLogLevelLabel = (logLevel = _chunkC5OTFOQBcjs.LogLevel.INFO) => {
33
30
  if (logLevel >= _chunkC5OTFOQBcjs.LogLevel.ALL) {
34
31
  return _chunkC5OTFOQBcjs.LogLevelLabel.ALL;
35
32
  }
@@ -55,11 +52,11 @@ var getLogLevelLabel = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, (lo
55
52
  return _chunkC5OTFOQBcjs.LogLevelLabel.SILENT;
56
53
  }
57
54
  return _chunkC5OTFOQBcjs.LogLevelLabel.INFO;
58
- }, "getLogLevelLabel");
59
- var isVerbose = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, (label = _chunkC5OTFOQBcjs.LogLevelLabel.SILENT) => {
55
+ };
56
+ var isVerbose = (label = _chunkC5OTFOQBcjs.LogLevelLabel.SILENT) => {
60
57
  const logLevel = typeof label === "string" ? getLogLevel(label) : label;
61
58
  return logLevel >= _chunkC5OTFOQBcjs.LogLevel.DEBUG;
62
- }, "isVerbose");
59
+ };
63
60
 
64
61
 
65
62
 
@@ -1,21 +1,18 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }
2
2
 
3
- var _chunkDLO4KL2Zcjs = require('./chunk-DLO4KL2Z.cjs');
3
+ var _chunk7SIKKF62cjs = require('./chunk-7SIKKF62.cjs');
4
4
 
5
5
 
6
- var _chunk6LIPH2JWcjs = require('./chunk-6LIPH2JW.cjs');
6
+ var _chunkAEZINHEAcjs = require('./chunk-AEZINHEA.cjs');
7
7
 
8
8
 
9
- var _chunkE5AUC34Gcjs = require('./chunk-E5AUC34G.cjs');
10
-
11
-
12
- var _chunkUSNT2KNTcjs = require('./chunk-USNT2KNT.cjs');
9
+ var _chunk4JREL2GQcjs = require('./chunk-4JREL2GQ.cjs');
13
10
 
14
11
  // src/config-file/get-config-file.ts
15
12
  var _c12 = require('c12');
16
13
  var _defu = require('defu'); var _defu2 = _interopRequireDefault(_defu);
17
- var getConfigFileByName = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, async (fileName, filePath, options = {}) => {
18
- const workspacePath = filePath || _chunk6LIPH2JWcjs.findWorkspaceRoot.call(void 0, filePath);
14
+ var getConfigFileByName = async (fileName, filePath, options = {}) => {
15
+ const workspacePath = filePath || _chunkAEZINHEAcjs.findWorkspaceRoot.call(void 0, filePath);
19
16
  const configs = await Promise.all([
20
17
  _c12.loadConfig.call(void 0, {
21
18
  cwd: workspacePath,
@@ -24,7 +21,10 @@ var getConfigFileByName = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0,
24
21
  envName: _optionalChain([fileName, 'optionalAccess', _ => _.toUpperCase, 'call', _2 => _2()]),
25
22
  jitiOptions: {
26
23
  debug: false,
27
- fsCache: process.env.STORM_SKIP_CACHE === "true" ? false : _chunkE5AUC34Gcjs.joinPaths.call(void 0, process.env.STORM_CACHE_DIR || "node_modules/.cache/storm", "jiti")
24
+ fsCache: process.env.STORM_SKIP_CACHE === "true" ? false : _chunk4JREL2GQcjs.joinPaths.call(void 0,
25
+ process.env.STORM_CACHE_DIR || "node_modules/.cache/storm",
26
+ "jiti"
27
+ )
28
28
  },
29
29
  ...options
30
30
  }),
@@ -35,32 +35,45 @@ var getConfigFileByName = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0,
35
35
  envName: _optionalChain([fileName, 'optionalAccess', _3 => _3.toUpperCase, 'call', _4 => _4()]),
36
36
  jitiOptions: {
37
37
  debug: false,
38
- fsCache: process.env.STORM_SKIP_CACHE === "true" ? false : _chunkE5AUC34Gcjs.joinPaths.call(void 0, process.env.STORM_CACHE_DIR || "node_modules/.cache/storm", "jiti")
38
+ fsCache: process.env.STORM_SKIP_CACHE === "true" ? false : _chunk4JREL2GQcjs.joinPaths.call(void 0,
39
+ process.env.STORM_CACHE_DIR || "node_modules/.cache/storm",
40
+ "jiti"
41
+ )
39
42
  },
40
43
  configFile: fileName,
41
44
  ...options
42
45
  })
43
46
  ]);
44
47
  return _defu2.default.call(void 0, _nullishCoalesce(configs[0], () => ( {})), _nullishCoalesce(configs[1], () => ( {})));
45
- }, "getConfigFileByName");
46
- var getConfigFile = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, async (filePath, additionalFileNames = []) => {
47
- const workspacePath = filePath ? filePath : _chunk6LIPH2JWcjs.findWorkspaceRoot.call(void 0, filePath);
48
+ };
49
+ var getConfigFile = async (filePath, additionalFileNames = []) => {
50
+ const workspacePath = filePath ? filePath : _chunkAEZINHEAcjs.findWorkspaceRoot.call(void 0, filePath);
48
51
  const result = await getConfigFileByName("storm-workspace", workspacePath);
49
52
  let config = result.config;
50
53
  const configFile = result.configFile;
51
54
  if (config && configFile && Object.keys(config).length > 0 && !config.skipConfigLogging) {
52
- _chunkDLO4KL2Zcjs.writeTrace.call(void 0, `Found Storm configuration file "${configFile.includes(`${workspacePath}/`) ? configFile.replace(`${workspacePath}/`, "") : configFile}" at "${workspacePath}"`, {
53
- logLevel: "all"
54
- });
55
+ _chunk7SIKKF62cjs.writeTrace.call(void 0,
56
+ `Found Storm configuration file "${configFile.includes(`${workspacePath}/`) ? configFile.replace(`${workspacePath}/`, "") : configFile}" at "${workspacePath}"`,
57
+ {
58
+ logLevel: "all"
59
+ }
60
+ );
55
61
  }
56
62
  if (additionalFileNames && additionalFileNames.length > 0) {
57
- const results = await Promise.all(additionalFileNames.map((fileName) => getConfigFileByName(fileName, workspacePath)));
63
+ const results = await Promise.all(
64
+ additionalFileNames.map(
65
+ (fileName) => getConfigFileByName(fileName, workspacePath)
66
+ )
67
+ );
58
68
  for (const result2 of results) {
59
69
  if (_optionalChain([result2, 'optionalAccess', _5 => _5.config]) && _optionalChain([result2, 'optionalAccess', _6 => _6.configFile]) && Object.keys(result2.config).length > 0) {
60
70
  if (!config.skipConfigLogging && !result2.config.skipConfigLogging) {
61
- _chunkDLO4KL2Zcjs.writeTrace.call(void 0, `Found alternative configuration file "${result2.configFile.includes(`${workspacePath}/`) ? result2.configFile.replace(`${workspacePath}/`, "") : result2.configFile}" at "${workspacePath}"`, {
62
- logLevel: "all"
63
- });
71
+ _chunk7SIKKF62cjs.writeTrace.call(void 0,
72
+ `Found alternative configuration file "${result2.configFile.includes(`${workspacePath}/`) ? result2.configFile.replace(`${workspacePath}/`, "") : result2.configFile}" at "${workspacePath}"`,
73
+ {
74
+ logLevel: "all"
75
+ }
76
+ );
64
77
  }
65
78
  config = _defu2.default.call(void 0, _nullishCoalesce(result2.config, () => ( {})), _nullishCoalesce(config, () => ( {})));
66
79
  }
@@ -71,7 +84,7 @@ var getConfigFile = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, async
71
84
  }
72
85
  config.configFile = configFile;
73
86
  return config;
74
- }, "getConfigFile");
87
+ };
75
88
 
76
89
 
77
90