@storm-software/unbuild 0.26.1 → 0.26.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.
@@ -1,12 +1,12 @@
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(); } } async function _asyncNullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return await 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 _chunkTRA2WJ3Wcjs = require('./chunk-TRA2WJ3W.cjs');
3
+ var _chunk5E3NJ26Lcjs = require('./chunk-5E3NJ26L.cjs');
4
4
 
5
5
 
6
- var _chunkHO6B5DC7cjs = require('./chunk-HO6B5DC7.cjs');
6
+ var _chunkY2DOCJBEcjs = require('./chunk-Y2DOCJBE.cjs');
7
7
 
8
8
 
9
- var _chunkKAXKUEZ7cjs = require('./chunk-KAXKUEZ7.cjs');
9
+ var _chunkV627S7QUcjs = require('./chunk-V627S7QU.cjs');
10
10
 
11
11
 
12
12
 
@@ -29,7 +29,7 @@ var _chunkKAXKUEZ7cjs = require('./chunk-KAXKUEZ7.cjs');
29
29
 
30
30
 
31
31
 
32
- var _chunkGHVDJY3Scjs = require('./chunk-GHVDJY3S.cjs');
32
+ var _chunkFG6XQ26Mcjs = require('./chunk-FG6XQ26M.cjs');
33
33
 
34
34
 
35
35
 
@@ -63,7 +63,7 @@ var _promises = require('fs/promises'); var _promises2 = _interopRequireDefault(
63
63
  var _c12 = require('c12');
64
64
  var _defu = require('defu'); var _defu2 = _interopRequireDefault(_defu);
65
65
  var getConfigFileByName = /* @__PURE__ */ _chunkYDYGZTJKcjs.__name.call(void 0, async (fileName, filePath, options = {}) => {
66
- const workspacePath = filePath || _chunkGHVDJY3Scjs.findWorkspaceRoot.call(void 0, filePath);
66
+ const workspacePath = filePath || _chunkFG6XQ26Mcjs.findWorkspaceRoot.call(void 0, filePath);
67
67
  let config = await _c12.loadConfig.call(void 0, {
68
68
  cwd: workspacePath,
69
69
  packageJson: true,
@@ -71,7 +71,7 @@ var getConfigFileByName = /* @__PURE__ */ _chunkYDYGZTJKcjs.__name.call(void 0,
71
71
  envName: _optionalChain([fileName, 'optionalAccess', _2 => _2.toUpperCase, 'call', _3 => _3()]),
72
72
  jitiOptions: {
73
73
  debug: false,
74
- fsCache: process.env.STORM_SKIP_CACHE === "true" ? false : _chunkGHVDJY3Scjs.joinPaths.call(void 0, process.env.STORM_CACHE_DIR || "node_modules/.cache/storm", "jiti")
74
+ fsCache: process.env.STORM_SKIP_CACHE === "true" ? false : _chunkFG6XQ26Mcjs.joinPaths.call(void 0, process.env.STORM_CACHE_DIR || "node_modules/.cache/storm", "jiti")
75
75
  },
76
76
  ...options
77
77
  });
@@ -83,7 +83,7 @@ var getConfigFileByName = /* @__PURE__ */ _chunkYDYGZTJKcjs.__name.call(void 0,
83
83
  envName: _optionalChain([fileName, 'optionalAccess', _4 => _4.toUpperCase, 'call', _5 => _5()]),
84
84
  jitiOptions: {
85
85
  debug: false,
86
- fsCache: process.env.STORM_SKIP_CACHE === "true" ? false : _chunkGHVDJY3Scjs.joinPaths.call(void 0, process.env.STORM_CACHE_DIR || "node_modules/.cache/storm", "jiti")
86
+ fsCache: process.env.STORM_SKIP_CACHE === "true" ? false : _chunkFG6XQ26Mcjs.joinPaths.call(void 0, process.env.STORM_CACHE_DIR || "node_modules/.cache/storm", "jiti")
87
87
  },
88
88
  configFile: fileName,
89
89
  ...options
@@ -92,12 +92,12 @@ var getConfigFileByName = /* @__PURE__ */ _chunkYDYGZTJKcjs.__name.call(void 0,
92
92
  return config;
93
93
  }, "getConfigFileByName");
94
94
  var getConfigFile = /* @__PURE__ */ _chunkYDYGZTJKcjs.__name.call(void 0, async (filePath, additionalFileNames = []) => {
95
- const workspacePath = filePath ? filePath : _chunkGHVDJY3Scjs.findWorkspaceRoot.call(void 0, filePath);
95
+ const workspacePath = filePath ? filePath : _chunkFG6XQ26Mcjs.findWorkspaceRoot.call(void 0, filePath);
96
96
  const result = await getConfigFileByName("storm", workspacePath);
97
97
  let config = result.config;
98
98
  const configFile = result.configFile;
99
99
  if (config && configFile && Object.keys(config).length > 0) {
100
- _chunkGHVDJY3Scjs.writeSystem.call(void 0, `Found Storm configuration file "${configFile.includes(`${workspacePath}/`) ? configFile.replace(`${workspacePath}/`, "") : configFile}" at "${workspacePath}"`, {
100
+ _chunkFG6XQ26Mcjs.writeSystem.call(void 0, `Found Storm configuration file "${configFile.includes(`${workspacePath}/`) ? configFile.replace(`${workspacePath}/`, "") : configFile}" at "${workspacePath}"`, {
101
101
  logLevel: "all"
102
102
  });
103
103
  }
@@ -105,7 +105,7 @@ var getConfigFile = /* @__PURE__ */ _chunkYDYGZTJKcjs.__name.call(void 0, async
105
105
  const results = await Promise.all(additionalFileNames.map((fileName) => getConfigFileByName(fileName, workspacePath)));
106
106
  for (const result2 of results) {
107
107
  if (_optionalChain([result2, 'optionalAccess', _6 => _6.config]) && _optionalChain([result2, 'optionalAccess', _7 => _7.configFile]) && Object.keys(result2.config).length > 0) {
108
- _chunkGHVDJY3Scjs.writeSystem.call(void 0, `Found alternative configuration file "${result2.configFile.includes(`${workspacePath}/`) ? result2.configFile.replace(`${workspacePath}/`, "") : result2.configFile}" at "${workspacePath}"`, {
108
+ _chunkFG6XQ26Mcjs.writeSystem.call(void 0, `Found alternative configuration file "${result2.configFile.includes(`${workspacePath}/`) ? result2.configFile.replace(`${workspacePath}/`, "") : result2.configFile}" at "${workspacePath}"`, {
109
109
  logLevel: "all"
110
110
  });
111
111
  config = _defu2.default.call(void 0, _nullishCoalesce(result2.config, () => ( {})), _nullishCoalesce(config, () => ( {})));
@@ -142,15 +142,15 @@ var getConfigEnv = /* @__PURE__ */ _chunkYDYGZTJKcjs.__name.call(void 0, () => {
142
142
  licensing: process.env[`${prefix}LICENSING`] || void 0,
143
143
  timezone: process.env[`${prefix}TIMEZONE`] || process.env.TZ || void 0,
144
144
  locale: process.env[`${prefix}LOCALE`] || process.env.LOCALE || void 0,
145
- configFile: process.env[`${prefix}CONFIG_FILE`] ? _chunkGHVDJY3Scjs.correctPaths.call(void 0, process.env[`${prefix}CONFIG_FILE`]) : void 0,
146
- workspaceRoot: process.env[`${prefix}WORKSPACE_ROOT`] ? _chunkGHVDJY3Scjs.correctPaths.call(void 0, process.env[`${prefix}WORKSPACE_ROOT`]) : void 0,
145
+ configFile: process.env[`${prefix}CONFIG_FILE`] ? _chunkFG6XQ26Mcjs.correctPaths.call(void 0, process.env[`${prefix}CONFIG_FILE`]) : void 0,
146
+ workspaceRoot: process.env[`${prefix}WORKSPACE_ROOT`] ? _chunkFG6XQ26Mcjs.correctPaths.call(void 0, process.env[`${prefix}WORKSPACE_ROOT`]) : void 0,
147
147
  directories: {
148
- cache: process.env[`${prefix}CACHE_DIR`] ? _chunkGHVDJY3Scjs.correctPaths.call(void 0, process.env[`${prefix}CACHE_DIR`]) : void 0,
149
- data: process.env[`${prefix}DATA_DIR`] ? _chunkGHVDJY3Scjs.correctPaths.call(void 0, process.env[`${prefix}DATA_DIR`]) : void 0,
150
- config: process.env[`${prefix}CONFIG_DIR`] ? _chunkGHVDJY3Scjs.correctPaths.call(void 0, process.env[`${prefix}CONFIG_DIR`]) : void 0,
151
- temp: process.env[`${prefix}TEMP_DIR`] ? _chunkGHVDJY3Scjs.correctPaths.call(void 0, process.env[`${prefix}TEMP_DIR`]) : void 0,
152
- log: process.env[`${prefix}LOG_DIR`] ? _chunkGHVDJY3Scjs.correctPaths.call(void 0, process.env[`${prefix}LOG_DIR`]) : void 0,
153
- build: process.env[`${prefix}BUILD_DIR`] ? _chunkGHVDJY3Scjs.correctPaths.call(void 0, process.env[`${prefix}BUILD_DIR`]) : void 0
148
+ cache: process.env[`${prefix}CACHE_DIR`] ? _chunkFG6XQ26Mcjs.correctPaths.call(void 0, process.env[`${prefix}CACHE_DIR`]) : void 0,
149
+ data: process.env[`${prefix}DATA_DIR`] ? _chunkFG6XQ26Mcjs.correctPaths.call(void 0, process.env[`${prefix}DATA_DIR`]) : void 0,
150
+ config: process.env[`${prefix}CONFIG_DIR`] ? _chunkFG6XQ26Mcjs.correctPaths.call(void 0, process.env[`${prefix}CONFIG_DIR`]) : void 0,
151
+ temp: process.env[`${prefix}TEMP_DIR`] ? _chunkFG6XQ26Mcjs.correctPaths.call(void 0, process.env[`${prefix}TEMP_DIR`]) : void 0,
152
+ log: process.env[`${prefix}LOG_DIR`] ? _chunkFG6XQ26Mcjs.correctPaths.call(void 0, process.env[`${prefix}LOG_DIR`]) : void 0,
153
+ build: process.env[`${prefix}BUILD_DIR`] ? _chunkFG6XQ26Mcjs.correctPaths.call(void 0, process.env[`${prefix}BUILD_DIR`]) : void 0
154
154
  },
155
155
  skipCache: process.env[`${prefix}SKIP_CACHE`] !== void 0 ? Boolean(process.env[`${prefix}SKIP_CACHE`]) : void 0,
156
156
  env: (_nullishCoalesce(_nullishCoalesce(process.env[`${prefix}ENV`], () => ( process.env.NODE_ENV)), () => ( process.env.ENVIRONMENT))) || void 0,
@@ -173,23 +173,23 @@ var getConfigEnv = /* @__PURE__ */ _chunkYDYGZTJKcjs.__name.call(void 0, () => {
173
173
  cyclone: process.env[`${prefix}REGISTRY_CYCLONE`] || void 0,
174
174
  container: process.env[`${prefix}REGISTRY_CONTAINER`] || void 0
175
175
  },
176
- 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`])) ? _chunkGHVDJY3Scjs.getLogLevelLabel.call(void 0, Number.parseInt(process.env[`${prefix}LOG_LEVEL`])) : process.env[`${prefix}LOG_LEVEL`] : void 0
176
+ 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`])) ? _chunkFG6XQ26Mcjs.getLogLevelLabel.call(void 0, Number.parseInt(process.env[`${prefix}LOG_LEVEL`])) : process.env[`${prefix}LOG_LEVEL`] : void 0
177
177
  };
178
- const themeNames = Object.keys(process.env).filter((envKey) => envKey.startsWith(`${prefix}COLOR_`) && _chunkGHVDJY3Scjs.COLOR_KEYS.every((colorKey) => !envKey.startsWith(`${prefix}COLOR_LIGHT_${colorKey}`) && !envKey.startsWith(`${prefix}COLOR_DARK_${colorKey}`)));
178
+ const themeNames = Object.keys(process.env).filter((envKey) => envKey.startsWith(`${prefix}COLOR_`) && _chunkFG6XQ26Mcjs.COLOR_KEYS.every((colorKey) => !envKey.startsWith(`${prefix}COLOR_LIGHT_${colorKey}`) && !envKey.startsWith(`${prefix}COLOR_DARK_${colorKey}`)));
179
179
  config.colors = themeNames.length > 0 ? themeNames.reduce((ret, themeName) => {
180
180
  ret[themeName] = getThemeColorConfigEnv(prefix, themeName);
181
181
  return ret;
182
182
  }, {}) : getThemeColorConfigEnv(prefix);
183
- if (config.docs === _chunkGHVDJY3Scjs.STORM_DEFAULT_DOCS) {
184
- if (config.homepage === _chunkGHVDJY3Scjs.STORM_DEFAULT_HOMEPAGE) {
185
- config.docs = `${_chunkGHVDJY3Scjs.STORM_DEFAULT_HOMEPAGE}/projects/${config.name}/docs`;
183
+ if (config.docs === _chunkFG6XQ26Mcjs.STORM_DEFAULT_DOCS) {
184
+ if (config.homepage === _chunkFG6XQ26Mcjs.STORM_DEFAULT_HOMEPAGE) {
185
+ config.docs = `${_chunkFG6XQ26Mcjs.STORM_DEFAULT_HOMEPAGE}/projects/${config.name}/docs`;
186
186
  } else {
187
187
  config.docs = `${config.homepage}/docs`;
188
188
  }
189
189
  }
190
- if (config.licensing === _chunkGHVDJY3Scjs.STORM_DEFAULT_LICENSING) {
191
- if (config.homepage === _chunkGHVDJY3Scjs.STORM_DEFAULT_HOMEPAGE) {
192
- config.licensing = `${_chunkGHVDJY3Scjs.STORM_DEFAULT_HOMEPAGE}/projects/${config.name}/licensing`;
190
+ if (config.licensing === _chunkFG6XQ26Mcjs.STORM_DEFAULT_LICENSING) {
191
+ if (config.homepage === _chunkFG6XQ26Mcjs.STORM_DEFAULT_HOMEPAGE) {
192
+ config.licensing = `${_chunkFG6XQ26Mcjs.STORM_DEFAULT_HOMEPAGE}/projects/${config.name}/licensing`;
193
193
  } else {
194
194
  config.licensing = `${config.homepage}/docs`;
195
195
  }
@@ -327,31 +327,31 @@ var setConfigEnv = /* @__PURE__ */ _chunkYDYGZTJKcjs.__name.call(void 0, (config
327
327
  process.env.LANG = config.locale ? `${config.locale.replaceAll("-", "_")}.UTF-8` : "en_US.UTF-8";
328
328
  }
329
329
  if (config.configFile) {
330
- process.env[`${prefix}CONFIG_FILE`] = _chunkGHVDJY3Scjs.correctPaths.call(void 0, config.configFile);
330
+ process.env[`${prefix}CONFIG_FILE`] = _chunkFG6XQ26Mcjs.correctPaths.call(void 0, config.configFile);
331
331
  }
332
332
  if (config.workspaceRoot) {
333
- process.env[`${prefix}WORKSPACE_ROOT`] = _chunkGHVDJY3Scjs.correctPaths.call(void 0, config.workspaceRoot);
334
- process.env.NX_WORKSPACE_ROOT = _chunkGHVDJY3Scjs.correctPaths.call(void 0, config.workspaceRoot);
335
- process.env.NX_WORKSPACE_ROOT_PATH = _chunkGHVDJY3Scjs.correctPaths.call(void 0, config.workspaceRoot);
333
+ process.env[`${prefix}WORKSPACE_ROOT`] = _chunkFG6XQ26Mcjs.correctPaths.call(void 0, config.workspaceRoot);
334
+ process.env.NX_WORKSPACE_ROOT = _chunkFG6XQ26Mcjs.correctPaths.call(void 0, config.workspaceRoot);
335
+ process.env.NX_WORKSPACE_ROOT_PATH = _chunkFG6XQ26Mcjs.correctPaths.call(void 0, config.workspaceRoot);
336
336
  }
337
337
  if (config.directories) {
338
338
  if (!config.skipCache && config.directories.cache) {
339
- process.env[`${prefix}CACHE_DIR`] = _chunkGHVDJY3Scjs.correctPaths.call(void 0, config.directories.cache);
339
+ process.env[`${prefix}CACHE_DIR`] = _chunkFG6XQ26Mcjs.correctPaths.call(void 0, config.directories.cache);
340
340
  }
341
341
  if (config.directories.data) {
342
- process.env[`${prefix}DATA_DIR`] = _chunkGHVDJY3Scjs.correctPaths.call(void 0, config.directories.data);
342
+ process.env[`${prefix}DATA_DIR`] = _chunkFG6XQ26Mcjs.correctPaths.call(void 0, config.directories.data);
343
343
  }
344
344
  if (config.directories.config) {
345
- process.env[`${prefix}CONFIG_DIR`] = _chunkGHVDJY3Scjs.correctPaths.call(void 0, config.directories.config);
345
+ process.env[`${prefix}CONFIG_DIR`] = _chunkFG6XQ26Mcjs.correctPaths.call(void 0, config.directories.config);
346
346
  }
347
347
  if (config.directories.temp) {
348
- process.env[`${prefix}TEMP_DIR`] = _chunkGHVDJY3Scjs.correctPaths.call(void 0, config.directories.temp);
348
+ process.env[`${prefix}TEMP_DIR`] = _chunkFG6XQ26Mcjs.correctPaths.call(void 0, config.directories.temp);
349
349
  }
350
350
  if (config.directories.log) {
351
- process.env[`${prefix}LOG_DIR`] = _chunkGHVDJY3Scjs.correctPaths.call(void 0, config.directories.log);
351
+ process.env[`${prefix}LOG_DIR`] = _chunkFG6XQ26Mcjs.correctPaths.call(void 0, config.directories.log);
352
352
  }
353
353
  if (config.directories.build) {
354
- process.env[`${prefix}BUILD_DIR`] = _chunkGHVDJY3Scjs.correctPaths.call(void 0, config.directories.build);
354
+ process.env[`${prefix}BUILD_DIR`] = _chunkFG6XQ26Mcjs.correctPaths.call(void 0, config.directories.build);
355
355
  }
356
356
  }
357
357
  if (config.skipCache !== void 0) {
@@ -405,8 +405,8 @@ var setConfigEnv = /* @__PURE__ */ _chunkYDYGZTJKcjs.__name.call(void 0, (config
405
405
  if (config.logLevel) {
406
406
  process.env[`${prefix}LOG_LEVEL`] = String(config.logLevel);
407
407
  process.env.LOG_LEVEL = String(config.logLevel);
408
- process.env.NX_VERBOSE_LOGGING = String(_chunkGHVDJY3Scjs.getLogLevel.call(void 0, config.logLevel) >= _chunkGHVDJY3Scjs.LogLevel.DEBUG ? true : false);
409
- process.env.RUST_BACKTRACE = _chunkGHVDJY3Scjs.getLogLevel.call(void 0, config.logLevel) >= _chunkGHVDJY3Scjs.LogLevel.DEBUG ? "full" : "none";
408
+ process.env.NX_VERBOSE_LOGGING = String(_chunkFG6XQ26Mcjs.getLogLevel.call(void 0, config.logLevel) >= _chunkFG6XQ26Mcjs.LogLevel.DEBUG ? true : false);
409
+ process.env.RUST_BACKTRACE = _chunkFG6XQ26Mcjs.getLogLevel.call(void 0, config.logLevel) >= _chunkFG6XQ26Mcjs.LogLevel.DEBUG ? "full" : "none";
410
410
  }
411
411
  process.env[`${prefix}CONFIG`] = JSON.stringify(config);
412
412
  for (const key of Object.keys(_nullishCoalesce(config.extensions, () => ( {})))) {
@@ -516,23 +516,23 @@ var _static_cache = void 0;
516
516
  var loadStormConfig = /* @__PURE__ */ _chunkYDYGZTJKcjs.__name.call(void 0, async (workspaceRoot) => {
517
517
  let config = {};
518
518
  if (_optionalChain([_static_cache, 'optionalAccess', _30 => _30.data]) && _optionalChain([_static_cache, 'optionalAccess', _31 => _31.timestamp]) && _static_cache.timestamp >= Date.now() + 3e4) {
519
- _chunkGHVDJY3Scjs.writeTrace.call(void 0, `Configuration cache hit - ${_static_cache.timestamp}`, _static_cache.data);
519
+ _chunkFG6XQ26Mcjs.writeTrace.call(void 0, `Configuration cache hit - ${_static_cache.timestamp}`, _static_cache.data);
520
520
  return _static_cache.data;
521
521
  }
522
522
  let _workspaceRoot = workspaceRoot;
523
523
  if (!_workspaceRoot) {
524
- _workspaceRoot = _chunkGHVDJY3Scjs.findWorkspaceRoot.call(void 0, );
524
+ _workspaceRoot = _chunkFG6XQ26Mcjs.findWorkspaceRoot.call(void 0, );
525
525
  }
526
526
  const configFile = await getConfigFile(_workspaceRoot);
527
527
  if (!configFile) {
528
- _chunkGHVDJY3Scjs.writeWarning.call(void 0, "No Storm config file found in the current workspace. Please ensure this is the expected behavior - you can add a `storm.json` file to the root of your workspace if it is not.\n", {
528
+ _chunkFG6XQ26Mcjs.writeWarning.call(void 0, "No Storm config file found in the current workspace. Please ensure this is the expected behavior - you can add a `storm.json` file to the root of your workspace if it is not.\n", {
529
529
  logLevel: "all"
530
530
  });
531
531
  }
532
- config = _defu2.default.call(void 0, getConfigEnv(), configFile, _chunkGHVDJY3Scjs.getDefaultConfig.call(void 0, _workspaceRoot));
532
+ config = _defu2.default.call(void 0, getConfigEnv(), configFile, _chunkFG6XQ26Mcjs.getDefaultConfig.call(void 0, _workspaceRoot));
533
533
  setConfigEnv(config);
534
- _chunkGHVDJY3Scjs.writeTrace.call(void 0, `\u2699\uFE0F Using Storm configuration:
535
- ${_chunkGHVDJY3Scjs.formatLogMessage.call(void 0, config)}`, config);
534
+ _chunkFG6XQ26Mcjs.writeTrace.call(void 0, `\u2699\uFE0F Using Storm configuration:
535
+ ${_chunkFG6XQ26Mcjs.formatLogMessage.call(void 0, config)}`, config);
536
536
  return config;
537
537
  }, "loadStormConfig");
538
538
 
@@ -545,7 +545,7 @@ var readNxConfig = /* @__PURE__ */ _chunkYDYGZTJKcjs.__name.call(void 0, async (
545
545
  const config = await loadStormConfig();
546
546
  rootDir = config.workspaceRoot;
547
547
  }
548
- const nxJsonPath = _chunkGHVDJY3Scjs.joinPaths.call(void 0, rootDir, "nx.json");
548
+ const nxJsonPath = _chunkFG6XQ26Mcjs.joinPaths.call(void 0, rootDir, "nx.json");
549
549
  if (!_fs.existsSync.call(void 0, nxJsonPath)) {
550
550
  throw new Error("Cannot find project.json configuration");
551
551
  }
@@ -592,7 +592,7 @@ var copyAssets = /* @__PURE__ */ _chunkYDYGZTJKcjs.__name.call(void 0, async (co
592
592
  }
593
593
  const buildTarget = _optionalChain([projectsConfigurations, 'access', _40 => _40.projects, 'access', _41 => _41[projectName], 'access', _42 => _42.targets, 'optionalAccess', _43 => _43.build]);
594
594
  if (!buildTarget) {
595
- throw new Error(`The Build process failed because the project does not have a valid build target in the project.json file. Check if the file exists in the root of the project at ${_chunkGHVDJY3Scjs.joinPaths.call(void 0, projectRoot, "project.json")}`);
595
+ throw new Error(`The Build process failed because the project does not have a valid build target in the project.json file. Check if the file exists in the root of the project at ${_chunkFG6XQ26Mcjs.joinPaths.call(void 0, projectRoot, "project.json")}`);
596
596
  }
597
597
  const result = await _js.copyAssets.call(void 0, {
598
598
  assets,
@@ -607,18 +607,18 @@ var copyAssets = /* @__PURE__ */ _chunkYDYGZTJKcjs.__name.call(void 0, async (co
607
607
  projectsConfigurations,
608
608
  nxJsonConfiguration: nxJson,
609
609
  cwd: config.workspaceRoot,
610
- isVerbose: _chunkGHVDJY3Scjs.isVerbose.call(void 0, config.logLevel)
610
+ isVerbose: _chunkFG6XQ26Mcjs.isVerbose.call(void 0, config.logLevel)
611
611
  });
612
612
  if (!result.success) {
613
613
  throw new Error("The Build process failed trying to copy assets");
614
614
  }
615
615
  if (includeSrc === true) {
616
- _chunkGHVDJY3Scjs.writeDebug.call(void 0, `\u{1F4DD} Adding banner and writing source files: ${_chunkGHVDJY3Scjs.joinPaths.call(void 0, outputPath, "src")}`, config);
616
+ _chunkFG6XQ26Mcjs.writeDebug.call(void 0, `\u{1F4DD} Adding banner and writing source files: ${_chunkFG6XQ26Mcjs.joinPaths.call(void 0, outputPath, "src")}`, config);
617
617
  const files = await _glob.glob.call(void 0, [
618
- _chunkGHVDJY3Scjs.joinPaths.call(void 0, config.workspaceRoot, outputPath, "src/**/*.ts"),
619
- _chunkGHVDJY3Scjs.joinPaths.call(void 0, config.workspaceRoot, outputPath, "src/**/*.tsx"),
620
- _chunkGHVDJY3Scjs.joinPaths.call(void 0, config.workspaceRoot, outputPath, "src/**/*.js"),
621
- _chunkGHVDJY3Scjs.joinPaths.call(void 0, config.workspaceRoot, outputPath, "src/**/*.jsx")
618
+ _chunkFG6XQ26Mcjs.joinPaths.call(void 0, config.workspaceRoot, outputPath, "src/**/*.ts"),
619
+ _chunkFG6XQ26Mcjs.joinPaths.call(void 0, config.workspaceRoot, outputPath, "src/**/*.tsx"),
620
+ _chunkFG6XQ26Mcjs.joinPaths.call(void 0, config.workspaceRoot, outputPath, "src/**/*.js"),
621
+ _chunkFG6XQ26Mcjs.joinPaths.call(void 0, config.workspaceRoot, outputPath, "src/**/*.jsx")
622
622
  ]);
623
623
  await Promise.allSettled(files.map(async (file) => _promises.writeFile.call(void 0, file, `${banner && typeof banner === "string" ? banner.startsWith("//") ? banner : `// ${banner}` : ""}
624
624
 
@@ -640,7 +640,7 @@ var addPackageDependencies = /* @__PURE__ */ _chunkYDYGZTJKcjs.__name.call(void
640
640
  for (const project of projectDependencies.dependencies.filter((dep) => dep.node.type === "lib" && dep.node.data.root !== projectRoot && dep.node.data.root !== workspaceRoot)) {
641
641
  const projectNode = project.node;
642
642
  if (projectNode.data.root) {
643
- const projectPackageJsonPath = _chunkGHVDJY3Scjs.joinPaths.call(void 0, workspaceRoot, projectNode.data.root, "package.json");
643
+ const projectPackageJsonPath = _chunkFG6XQ26Mcjs.joinPaths.call(void 0, workspaceRoot, projectNode.data.root, "package.json");
644
644
  if (_fs.existsSync.call(void 0, projectPackageJsonPath)) {
645
645
  const projectPackageJsonContent = await _promises.readFile.call(void 0, projectPackageJsonPath, "utf8");
646
646
  const projectPackageJson = JSON.parse(projectPackageJsonContent);
@@ -651,7 +651,7 @@ var addPackageDependencies = /* @__PURE__ */ _chunkYDYGZTJKcjs.__name.call(void
651
651
  }
652
652
  }
653
653
  if (localPackages.length > 0) {
654
- _chunkGHVDJY3Scjs.writeTrace.call(void 0, `\u{1F4E6} Adding local packages to package.json: ${localPackages.map((p) => p.name).join(", ")}`);
654
+ _chunkFG6XQ26Mcjs.writeTrace.call(void 0, `\u{1F4E6} Adding local packages to package.json: ${localPackages.map((p) => p.name).join(", ")}`);
655
655
  packageJson.peerDependencies = localPackages.reduce((ret, localPackage) => {
656
656
  if (!ret[localPackage.name]) {
657
657
  ret[localPackage.name] = `>=${localPackage.version || "0.0.1"}`;
@@ -673,13 +673,13 @@ var addPackageDependencies = /* @__PURE__ */ _chunkYDYGZTJKcjs.__name.call(void
673
673
  return ret;
674
674
  }, _nullishCoalesce(packageJson.peerDependencies, () => ( {})));
675
675
  } else {
676
- _chunkGHVDJY3Scjs.writeTrace.call(void 0, "\u{1F4E6} No local packages dependencies to add to package.json");
676
+ _chunkFG6XQ26Mcjs.writeTrace.call(void 0, "\u{1F4E6} No local packages dependencies to add to package.json");
677
677
  }
678
678
  return packageJson;
679
679
  }, "addPackageDependencies");
680
680
  var addWorkspacePackageJsonFields = /* @__PURE__ */ _chunkYDYGZTJKcjs.__name.call(void 0, async (config, projectRoot, sourceRoot, projectName, includeSrc = false, packageJson) => {
681
- const workspaceRoot = config.workspaceRoot ? config.workspaceRoot : _chunkGHVDJY3Scjs.findWorkspaceRoot.call(void 0, );
682
- const workspacePackageJsonContent = await _promises.readFile.call(void 0, _chunkGHVDJY3Scjs.joinPaths.call(void 0, workspaceRoot, "package.json"), "utf8");
681
+ const workspaceRoot = config.workspaceRoot ? config.workspaceRoot : _chunkFG6XQ26Mcjs.findWorkspaceRoot.call(void 0, );
682
+ const workspacePackageJsonContent = await _promises.readFile.call(void 0, _chunkFG6XQ26Mcjs.joinPaths.call(void 0, workspaceRoot, "package.json"), "utf8");
683
683
  const workspacePackageJson = JSON.parse(workspacePackageJsonContent);
684
684
  packageJson.type ??= "module";
685
685
  packageJson.sideEffects ??= false;
@@ -688,7 +688,7 @@ var addWorkspacePackageJsonFields = /* @__PURE__ */ _chunkYDYGZTJKcjs.__name.cal
688
688
  if (distSrc.startsWith("/")) {
689
689
  distSrc = distSrc.substring(1);
690
690
  }
691
- packageJson.source ??= `${_chunkGHVDJY3Scjs.joinPaths.call(void 0, distSrc, "index.ts").replaceAll("\\", "/")}`;
691
+ packageJson.source ??= `${_chunkFG6XQ26Mcjs.joinPaths.call(void 0, distSrc, "index.ts").replaceAll("\\", "/")}`;
692
692
  }
693
693
  packageJson.files ??= [
694
694
  "dist/**/*"
@@ -719,7 +719,7 @@ var addWorkspacePackageJsonFields = /* @__PURE__ */ _chunkYDYGZTJKcjs.__name.cal
719
719
  ];
720
720
  }
721
721
  packageJson.repository ??= workspacePackageJson.repository;
722
- packageJson.repository.directory ??= projectRoot ? projectRoot : _chunkGHVDJY3Scjs.joinPaths.call(void 0, "packages", projectName);
722
+ packageJson.repository.directory ??= projectRoot ? projectRoot : _chunkFG6XQ26Mcjs.joinPaths.call(void 0, "packages", projectName);
723
723
  return packageJson;
724
724
  }, "addWorkspacePackageJsonFields");
725
725
  var addPackageJsonExport = /* @__PURE__ */ _chunkYDYGZTJKcjs.__name.call(void 0, (file, type = "module", sourceRoot) => {
@@ -2217,24 +2217,24 @@ _chunkYDYGZTJKcjs.__name.call(void 0, _build, "_build");
2217
2217
 
2218
2218
  // src/build.ts
2219
2219
  async function resolveOptions(options, config) {
2220
- _chunkGHVDJY3Scjs.writeDebug.call(void 0, " \u2699\uFE0F Resolving build options", config);
2221
- const stopwatch = _chunkGHVDJY3Scjs.getStopwatch.call(void 0, "Build options resolution");
2220
+ _chunkFG6XQ26Mcjs.writeDebug.call(void 0, " \u2699\uFE0F Resolving build options", config);
2221
+ const stopwatch = _chunkFG6XQ26Mcjs.getStopwatch.call(void 0, "Build options resolution");
2222
2222
  if (options.configPath) {
2223
- const configFile = await _chunkKAXKUEZ7cjs.loadConfig.call(void 0, options.configPath);
2223
+ const configFile = await _chunkV627S7QUcjs.loadConfig.call(void 0, options.configPath);
2224
2224
  if (configFile) {
2225
2225
  options = _defu2.default.call(void 0, options, configFile);
2226
2226
  }
2227
2227
  }
2228
- const outputPath = options.outputPath || _chunkGHVDJY3Scjs.joinPaths.call(void 0, "dist", options.projectRoot);
2228
+ const outputPath = options.outputPath || _chunkFG6XQ26Mcjs.joinPaths.call(void 0, "dist", options.projectRoot);
2229
2229
  const projectGraph = _devkit.readCachedProjectGraph.call(void 0, );
2230
- const projectJsonPath = _chunkGHVDJY3Scjs.joinPaths.call(void 0, config.workspaceRoot, options.projectRoot, "project.json");
2230
+ const projectJsonPath = _chunkFG6XQ26Mcjs.joinPaths.call(void 0, config.workspaceRoot, options.projectRoot, "project.json");
2231
2231
  if (!_fs.existsSync.call(void 0, projectJsonPath)) {
2232
2232
  throw new Error("Cannot find project.json configuration");
2233
2233
  }
2234
2234
  const projectJsonContent = await _promises.readFile.call(void 0, projectJsonPath, "utf8");
2235
2235
  const projectJson = JSON.parse(projectJsonContent);
2236
2236
  const projectName = projectJson.name;
2237
- const packageJsonPath = _chunkGHVDJY3Scjs.joinPaths.call(void 0, config.workspaceRoot, options.projectRoot, "package.json");
2237
+ const packageJsonPath = _chunkFG6XQ26Mcjs.joinPaths.call(void 0, config.workspaceRoot, options.projectRoot, "package.json");
2238
2238
  if (!_fs.existsSync.call(void 0, packageJsonPath)) {
2239
2239
  throw new Error("Cannot find package.json configuration");
2240
2240
  }
@@ -2242,14 +2242,14 @@ async function resolveOptions(options, config) {
2242
2242
  const packageJson = JSON.parse(packageJsonContent);
2243
2243
  let tsconfig = options.tsconfig;
2244
2244
  if (!tsconfig) {
2245
- tsconfig = _chunkGHVDJY3Scjs.joinPaths.call(void 0, config.workspaceRoot, options.projectRoot, "tsconfig.json");
2245
+ tsconfig = _chunkFG6XQ26Mcjs.joinPaths.call(void 0, config.workspaceRoot, options.projectRoot, "tsconfig.json");
2246
2246
  }
2247
2247
  if (!_fs.existsSync.call(void 0, tsconfig)) {
2248
2248
  throw new Error("Cannot find tsconfig.json configuration");
2249
2249
  }
2250
2250
  let sourceRoot = projectJson.sourceRoot;
2251
2251
  if (!sourceRoot) {
2252
- sourceRoot = _chunkGHVDJY3Scjs.joinPaths.call(void 0, options.projectRoot, "src");
2252
+ sourceRoot = _chunkFG6XQ26Mcjs.joinPaths.call(void 0, options.projectRoot, "src");
2253
2253
  }
2254
2254
  if (!_fs.existsSync.call(void 0, sourceRoot)) {
2255
2255
  throw new Error("Cannot find sourceRoot directory");
@@ -2273,14 +2273,14 @@ async function resolveOptions(options, config) {
2273
2273
  {
2274
2274
  builder: "mkdist",
2275
2275
  input: `.${sourceRoot.replace(options.projectRoot, "")}`,
2276
- outDir: _chunkGHVDJY3Scjs.joinPaths.call(void 0, _path.relative.call(void 0, _chunkGHVDJY3Scjs.joinPaths.call(void 0, config.workspaceRoot, options.projectRoot), config.workspaceRoot).replaceAll("\\", "/"), outputPath, "dist").replaceAll("\\", "/"),
2276
+ outDir: _chunkFG6XQ26Mcjs.joinPaths.call(void 0, _path.relative.call(void 0, _chunkFG6XQ26Mcjs.joinPaths.call(void 0, config.workspaceRoot, options.projectRoot), config.workspaceRoot), outputPath, "dist"),
2277
2277
  declaration: options.emitTypes !== false,
2278
2278
  format: "esm"
2279
2279
  },
2280
2280
  {
2281
2281
  builder: "mkdist",
2282
2282
  input: `.${sourceRoot.replace(options.projectRoot, "")}`,
2283
- outDir: _chunkGHVDJY3Scjs.joinPaths.call(void 0, _path.relative.call(void 0, _chunkGHVDJY3Scjs.joinPaths.call(void 0, config.workspaceRoot, options.projectRoot), config.workspaceRoot).replaceAll("\\", "/"), outputPath, "dist").replaceAll("\\", "/"),
2283
+ outDir: _chunkFG6XQ26Mcjs.joinPaths.call(void 0, _path.relative.call(void 0, _chunkFG6XQ26Mcjs.joinPaths.call(void 0, config.workspaceRoot, options.projectRoot), config.workspaceRoot), outputPath, "dist"),
2284
2284
  declaration: options.emitTypes !== false,
2285
2285
  format: "cjs",
2286
2286
  ext: "cjs"
@@ -2338,7 +2338,7 @@ async function resolveOptions(options, config) {
2338
2338
  splitting: options.splitting !== false,
2339
2339
  treeShaking: options.treeShaking !== false,
2340
2340
  color: true,
2341
- logLevel: config.logLevel === _chunkGHVDJY3Scjs.LogLevelLabel.FATAL ? _chunkGHVDJY3Scjs.LogLevelLabel.ERROR : _chunkGHVDJY3Scjs.isVerbose.call(void 0, ) ? "verbose" : config.logLevel
2341
+ logLevel: config.logLevel === _chunkFG6XQ26Mcjs.LogLevelLabel.FATAL ? _chunkFG6XQ26Mcjs.LogLevelLabel.ERROR : _chunkFG6XQ26Mcjs.isVerbose.call(void 0, ) ? "verbose" : config.logLevel
2342
2342
  }
2343
2343
  }
2344
2344
  };
@@ -2355,7 +2355,7 @@ async function resolveOptions(options, config) {
2355
2355
  if (options.rollup) {
2356
2356
  let rollup2 = {};
2357
2357
  if (typeof options.rollup === "string") {
2358
- const rollupFile = await _chunkKAXKUEZ7cjs.loadConfig.call(void 0, options.rollup);
2358
+ const rollupFile = await _chunkV627S7QUcjs.loadConfig.call(void 0, options.rollup);
2359
2359
  if (rollupFile) {
2360
2360
  rollup2 = rollupFile;
2361
2361
  }
@@ -2366,7 +2366,7 @@ async function resolveOptions(options, config) {
2366
2366
  }
2367
2367
  resolvedOptions.hooks = {
2368
2368
  "rollup:options": /* @__PURE__ */ _chunkYDYGZTJKcjs.__name.call(void 0, async (ctx, opts) => {
2369
- opts.plugins = await _asyncNullishCoalesce(options.plugins, async () => ( await _chunkHO6B5DC7cjs.getDefaultBuildPlugins.call(void 0, options, resolvedOptions)));
2369
+ opts.plugins = await _asyncNullishCoalesce(options.plugins, async () => ( await _chunkY2DOCJBEcjs.getDefaultBuildPlugins.call(void 0, options, resolvedOptions)));
2370
2370
  }, "rollup:options")
2371
2371
  };
2372
2372
  stopwatch();
@@ -2374,35 +2374,39 @@ async function resolveOptions(options, config) {
2374
2374
  }
2375
2375
  _chunkYDYGZTJKcjs.__name.call(void 0, resolveOptions, "resolveOptions");
2376
2376
  async function generatePackageJson(options) {
2377
- if (options.generatePackageJson !== false && _fs.existsSync.call(void 0, _chunkGHVDJY3Scjs.joinPaths.call(void 0, options.projectRoot, "package.json"))) {
2378
- _chunkGHVDJY3Scjs.writeDebug.call(void 0, " \u270D\uFE0F Writing package.json file", options.config);
2379
- const stopwatch = _chunkGHVDJY3Scjs.getStopwatch.call(void 0, "Write package.json file");
2380
- const packageJsonPath = _chunkGHVDJY3Scjs.joinPaths.call(void 0, options.projectRoot, "project.json");
2377
+ if (options.generatePackageJson !== false && _fs.existsSync.call(void 0, _chunkFG6XQ26Mcjs.joinPaths.call(void 0, options.projectRoot, "package.json"))) {
2378
+ _chunkFG6XQ26Mcjs.writeDebug.call(void 0, " \u270D\uFE0F Writing package.json file", options.config);
2379
+ const stopwatch = _chunkFG6XQ26Mcjs.getStopwatch.call(void 0, "Write package.json file");
2380
+ const packageJsonPath = _chunkFG6XQ26Mcjs.joinPaths.call(void 0, options.projectRoot, "project.json");
2381
2381
  if (!_fs.existsSync.call(void 0, packageJsonPath)) {
2382
2382
  throw new Error("Cannot find package.json configuration");
2383
2383
  }
2384
- let packageJsonContent = await _promises.readFile.call(void 0, _chunkGHVDJY3Scjs.joinPaths.call(void 0, options.config.workspaceRoot, options.projectRoot, "package.json"), "utf8");
2384
+ let packageJsonContent = await _promises.readFile.call(void 0, _chunkFG6XQ26Mcjs.joinPaths.call(void 0, options.config.workspaceRoot, options.projectRoot, "package.json"), "utf8");
2385
2385
  if (!packageJsonContent) {
2386
2386
  throw new Error("Cannot find package.json configuration file");
2387
2387
  }
2388
2388
  let packageJson = JSON.parse(packageJsonContent);
2389
2389
  packageJson = await addPackageDependencies(options.config.workspaceRoot, options.projectRoot, options.projectName, packageJson);
2390
2390
  packageJson = await addWorkspacePackageJsonFields(options.config, options.projectRoot, options.sourceRoot, options.projectName, false, packageJson);
2391
- await _devkit.writeJsonFile.call(void 0, _chunkGHVDJY3Scjs.joinPaths.call(void 0, options.outDir, "package.json"), await addPackageJsonExports(options.sourceRoot, packageJson));
2391
+ await _devkit.writeJsonFile.call(void 0, _chunkFG6XQ26Mcjs.joinPaths.call(void 0, options.outDir, "package.json"), await addPackageJsonExports(options.sourceRoot, packageJson));
2392
2392
  stopwatch();
2393
2393
  }
2394
2394
  return options;
2395
2395
  }
2396
2396
  _chunkYDYGZTJKcjs.__name.call(void 0, generatePackageJson, "generatePackageJson");
2397
2397
  async function executeUnbuild(options) {
2398
- _chunkGHVDJY3Scjs.writeDebug.call(void 0, ` \u{1F680} Running ${options.name} (${options.projectRoot}) build`, options.config);
2399
- const stopwatch = _chunkGHVDJY3Scjs.getStopwatch.call(void 0, `${options.name} (${options.projectRoot}) build`);
2398
+ _chunkFG6XQ26Mcjs.writeDebug.call(void 0, ` \u{1F680} Running ${options.name} (${options.projectRoot}) build`, options.config);
2399
+ const stopwatch = _chunkFG6XQ26Mcjs.getStopwatch.call(void 0, `${options.name} (${options.projectRoot}) build`);
2400
2400
  try {
2401
- await build(options.projectRoot, false, {
2401
+ const config = {
2402
2402
  ...options,
2403
2403
  config: null,
2404
2404
  rootDir: options.projectRoot
2405
- });
2405
+ };
2406
+ _chunkFG6XQ26Mcjs.writeTrace.call(void 0, `Running with unbuild configuration:
2407
+ ${_chunkFG6XQ26Mcjs.formatLogMessage.call(void 0, config)}
2408
+ `, options.config);
2409
+ await build(options.projectRoot, false, config);
2406
2410
  } finally {
2407
2411
  stopwatch();
2408
2412
  }
@@ -2410,8 +2414,8 @@ async function executeUnbuild(options) {
2410
2414
  }
2411
2415
  _chunkYDYGZTJKcjs.__name.call(void 0, executeUnbuild, "executeUnbuild");
2412
2416
  async function copyBuildAssets(options) {
2413
- _chunkGHVDJY3Scjs.writeDebug.call(void 0, ` \u{1F4CB} Copying asset files to output directory: ${options.outDir}`, options.config);
2414
- const stopwatch = _chunkGHVDJY3Scjs.getStopwatch.call(void 0, `${options.name} asset copy`);
2417
+ _chunkFG6XQ26Mcjs.writeDebug.call(void 0, ` \u{1F4CB} Copying asset files to output directory: ${options.outDir}`, options.config);
2418
+ const stopwatch = _chunkFG6XQ26Mcjs.getStopwatch.call(void 0, `${options.name} asset copy`);
2415
2419
  await copyAssets(options.config, _nullishCoalesce(options.assets, () => ( [])), options.outDir, options.projectRoot, options.projectName, options.sourceRoot, options.generatePackageJson, options.includeSrc);
2416
2420
  stopwatch();
2417
2421
  return options;
@@ -2419,9 +2423,9 @@ async function copyBuildAssets(options) {
2419
2423
  _chunkYDYGZTJKcjs.__name.call(void 0, copyBuildAssets, "copyBuildAssets");
2420
2424
  async function cleanOutputPath(options) {
2421
2425
  if (options.clean !== false && options.outDir) {
2422
- _chunkGHVDJY3Scjs.writeDebug.call(void 0, ` \u{1F9F9} Cleaning ${options.name} output path: ${options.outDir}`, options.config);
2423
- const stopwatch = _chunkGHVDJY3Scjs.getStopwatch.call(void 0, `${options.name} output clean`);
2424
- await _chunkTRA2WJ3Wcjs.cleanDirectories.call(void 0, options.name, options.outDir, options.config);
2426
+ _chunkFG6XQ26Mcjs.writeDebug.call(void 0, ` \u{1F9F9} Cleaning ${options.name} output path: ${options.outDir}`, options.config);
2427
+ const stopwatch = _chunkFG6XQ26Mcjs.getStopwatch.call(void 0, `${options.name} output clean`);
2428
+ await _chunk5E3NJ26Lcjs.cleanDirectories.call(void 0, options.name, options.outDir, options.config);
2425
2429
  stopwatch();
2426
2430
  }
2427
2431
  return options;
@@ -2437,18 +2441,18 @@ async function build2(options) {
2437
2441
  throw new Error("Cannot find workspace root");
2438
2442
  }
2439
2443
  const config = await loadStormConfig(workspaceRoot.dir);
2440
- _chunkGHVDJY3Scjs.writeDebug.call(void 0, ` \u26A1 Executing Storm Unbuild pipeline`, config);
2441
- const stopwatch = _chunkGHVDJY3Scjs.getStopwatch.call(void 0, "Unbuild pipeline");
2444
+ _chunkFG6XQ26Mcjs.writeDebug.call(void 0, ` \u26A1 Executing Storm Unbuild pipeline`, config);
2445
+ const stopwatch = _chunkFG6XQ26Mcjs.getStopwatch.call(void 0, "Unbuild pipeline");
2442
2446
  try {
2443
- options.projectRoot = projectRoot;
2447
+ options.projectRoot = _chunkFG6XQ26Mcjs.correctPaths.call(void 0, projectRoot);
2444
2448
  const resolvedOptions = await resolveOptions(options, config);
2445
2449
  await cleanOutputPath(resolvedOptions);
2446
2450
  await generatePackageJson(resolvedOptions);
2447
2451
  await executeUnbuild(resolvedOptions);
2448
2452
  await copyBuildAssets(resolvedOptions);
2449
- _chunkGHVDJY3Scjs.writeSuccess.call(void 0, ` \u{1F3C1} The ${resolvedOptions.name} build completed successfully`, config);
2453
+ _chunkFG6XQ26Mcjs.writeSuccess.call(void 0, ` \u{1F3C1} The ${resolvedOptions.name} build completed successfully`, config);
2450
2454
  } catch (error) {
2451
- _chunkGHVDJY3Scjs.writeFatal.call(void 0, " \u274C Fatal errors occurred during the build that could not be recovered from. The build process has been terminated.", config);
2455
+ _chunkFG6XQ26Mcjs.writeFatal.call(void 0, " \u274C Fatal errors occurred during the build that could not be recovered from. The build process has been terminated.", config);
2452
2456
  throw error;
2453
2457
  } finally {
2454
2458
  stopwatch();
@@ -481,49 +481,56 @@ var formatTimestamp = /* @__PURE__ */ __name((date = /* @__PURE__ */ new Date())
481
481
  var getLogFn = /* @__PURE__ */ __name((logLevel = LogLevel.INFO, config = {}, _chalk = getChalk()) => {
482
482
  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;
483
483
  const configLogLevel = config.logLevel || process.env.STORM_LOG_LEVEL || LogLevelLabel.INFO;
484
- if (typeof logLevel === "number" && (logLevel >= getLogLevel(configLogLevel) || logLevel <= LogLevel.SILENT) || typeof logLevel === "string" && getLogLevel(logLevel) >= getLogLevel(configLogLevel)) {
484
+ if (logLevel > getLogLevel(configLogLevel) || logLevel <= LogLevel.SILENT || getLogLevel(configLogLevel) <= LogLevel.SILENT) {
485
485
  return (_) => {
486
486
  };
487
487
  }
488
- if (typeof logLevel === "number" && LogLevel.FATAL >= logLevel || typeof logLevel === "string" && LogLevel.FATAL >= getLogLevel(logLevel)) {
488
+ if (typeof logLevel === "number" && LogLevel.FATAL >= logLevel) {
489
489
  return (message) => {
490
490
  console.error(`
491
491
  ${_chalk.gray(formatTimestamp())} ${_chalk.hex(colors.fatal ?? "#7d1a1a")(`[${CONSOLE_ICONS[LogLevelLabel.FATAL]} Fatal]`)} ${_chalk.bold.whiteBright(formatLogMessage(message))}
492
492
  `);
493
493
  };
494
494
  }
495
- if (typeof logLevel === "number" && LogLevel.ERROR >= logLevel || typeof logLevel === "string" && LogLevel.ERROR >= getLogLevel(logLevel)) {
495
+ if (typeof logLevel === "number" && LogLevel.ERROR >= logLevel) {
496
496
  return (message) => {
497
497
  console.error(`
498
498
  ${_chalk.gray(formatTimestamp())} ${_chalk.hex(colors.danger ?? "#f85149")(`[${CONSOLE_ICONS[LogLevelLabel.ERROR]} Error]`)} ${_chalk.bold.whiteBright(formatLogMessage(message))}
499
499
  `);
500
500
  };
501
501
  }
502
- if (typeof logLevel === "number" && LogLevel.WARN >= logLevel || typeof logLevel === "string" && LogLevel.WARN >= getLogLevel(logLevel)) {
502
+ if (typeof logLevel === "number" && LogLevel.WARN >= logLevel) {
503
503
  return (message) => {
504
504
  console.warn(`
505
505
  ${_chalk.gray(formatTimestamp())} ${_chalk.hex(colors.warning ?? "#e3b341")(`[${CONSOLE_ICONS[LogLevelLabel.WARN]} Warn]`)} ${_chalk.bold.whiteBright(formatLogMessage(message))}
506
506
  `);
507
507
  };
508
508
  }
509
- if (typeof logLevel === "number" && LogLevel.SUCCESS >= logLevel || typeof logLevel === "string" && LogLevel.SUCCESS >= getLogLevel(logLevel)) {
509
+ if (typeof logLevel === "number" && LogLevel.SUCCESS >= logLevel) {
510
510
  return (message) => {
511
511
  console.info(`
512
512
  ${_chalk.gray(formatTimestamp())} ${_chalk.hex(colors.success ?? "#56d364")(`[${CONSOLE_ICONS[LogLevelLabel.SUCCESS]} Success]`)} ${_chalk.bold.whiteBright(formatLogMessage(message))}
513
513
  `);
514
514
  };
515
515
  }
516
- if (typeof logLevel === "number" && LogLevel.INFO >= logLevel || typeof logLevel === "string" && LogLevel.INFO >= getLogLevel(logLevel)) {
516
+ if (typeof logLevel === "number" && LogLevel.INFO >= logLevel) {
517
517
  return (message) => {
518
518
  console.info(`
519
519
  ${_chalk.gray(formatTimestamp())} ${_chalk.hex(colors.info ?? "#58a6ff")(`[${CONSOLE_ICONS[LogLevelLabel.INFO]} Info]`)} ${_chalk.bold.whiteBright(formatLogMessage(message))}
520
520
  `);
521
521
  };
522
522
  }
523
- if (typeof logLevel === "number" && LogLevel.TRACE >= logLevel || typeof logLevel === "string" && LogLevel.TRACE >= getLogLevel(logLevel)) {
523
+ if (typeof logLevel === "number" && LogLevel.DEBUG >= logLevel) {
524
524
  return (message) => {
525
525
  console.debug(`
526
- ${_chalk.gray(formatTimestamp())} ${_chalk.hex(colors.brand ?? "#1fb2a6")(`[${CONSOLE_ICONS[LogLevelLabel.DEBUG]} Debug]`)} ${_chalk.bold.whiteBright(formatLogMessage(message))}
526
+ ${_chalk.gray(formatTimestamp())} ${_chalk.hex(colors.brand ?? "#1fb2a6")(`[${CONSOLE_ICONS[LogLevelLabel.DEBUG]} Debug]`)} ${_chalk.bold.whiteBright(formatLogMessage(message))}
527
+ `);
528
+ };
529
+ }
530
+ if (typeof logLevel === "number" && LogLevel.TRACE >= logLevel) {
531
+ return (message) => {
532
+ console.debug(`
533
+ ${_chalk.gray(formatTimestamp())} ${_chalk.hex(colors.brand ?? "#1fb2a6")(`[${CONSOLE_ICONS[LogLevelLabel.TRACE]} Trace]`)} ${_chalk.bold.whiteBright(formatLogMessage(message))}
527
534
  `);
528
535
  };
529
536
  }
@@ -1,6 +1,6 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { newObj[key] = obj[key]; } } } newObj.default = obj; return newObj; } } function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } }
2
2
 
3
- var _chunkGHVDJY3Scjs = require('./chunk-GHVDJY3S.cjs');
3
+ var _chunkFG6XQ26Mcjs = require('./chunk-FG6XQ26M.cjs');
4
4
 
5
5
 
6
6
  var _chunkYDYGZTJKcjs = require('./chunk-YDYGZTJK.cjs');
@@ -32,7 +32,7 @@ async function createTsCompilerOptions(config, tsConfigPath, projectRoot, depend
32
32
  declaration: true,
33
33
  paths: _buildablelibsutils.computeCompilerOptionsPaths.call(void 0, tsConfig, _nullishCoalesce(dependencies, () => ( [])))
34
34
  };
35
- _chunkGHVDJY3Scjs.writeTrace.call(void 0, compilerOptions, config);
35
+ _chunkFG6XQ26Mcjs.writeTrace.call(void 0, compilerOptions, config);
36
36
  return compilerOptions;
37
37
  }
38
38
  _chunkYDYGZTJKcjs.__name.call(void 0, createTsCompilerOptions, "createTsCompilerOptions");
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  getStopwatch,
3
3
  writeDebug
4
- } from "./chunk-BRHZNXQM.js";
4
+ } from "./chunk-TPFSDZCR.js";
5
5
  import {
6
6
  __name
7
7
  } from "./chunk-3GQAWCBQ.js";
@@ -1,25 +1,25 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
2
 
3
- var _chunkKAXKUEZ7cjs = require('./chunk-KAXKUEZ7.cjs');
3
+ var _chunkV627S7QUcjs = require('./chunk-V627S7QU.cjs');
4
4
 
5
5
 
6
6
  var _chunkSHHAZOHNcjs = require('./chunk-SHHAZOHN.cjs');
7
7
 
8
8
 
9
- var _chunkUV35N5R4cjs = require('./chunk-UV35N5R4.cjs');
9
+ var _chunkPSYW5YJBcjs = require('./chunk-PSYW5YJB.cjs');
10
10
 
11
11
 
12
- var _chunkXKHSZIHPcjs = require('./chunk-XKHSZIHP.cjs');
12
+ var _chunkCF2C3GEVcjs = require('./chunk-CF2C3GEV.cjs');
13
13
 
14
14
 
15
15
  var _chunkYDYGZTJKcjs = require('./chunk-YDYGZTJK.cjs');
16
16
 
17
17
  // src/config.ts
18
18
  var getDefaultBuildPlugins = /* @__PURE__ */ _chunkYDYGZTJKcjs.__name.call(void 0, async (options, resolvedOptions) => Promise.all([
19
- _chunkUV35N5R4cjs.analyzePlugin.call(void 0, options, resolvedOptions),
19
+ _chunkPSYW5YJBcjs.analyzePlugin.call(void 0, options, resolvedOptions),
20
20
  _chunkSHHAZOHNcjs.typeDefinitions.call(void 0, resolvedOptions.projectRoot),
21
- _chunkKAXKUEZ7cjs.tscPlugin.call(void 0, options, resolvedOptions),
22
- _chunkXKHSZIHPcjs.onErrorPlugin.call(void 0, options, resolvedOptions)
21
+ _chunkV627S7QUcjs.tscPlugin.call(void 0, options, resolvedOptions),
22
+ _chunkCF2C3GEVcjs.onErrorPlugin.call(void 0, options, resolvedOptions)
23
23
  ].map((plugin) => Promise.resolve(plugin))), "getDefaultBuildPlugins");
24
24
 
25
25