@storm-software/build-tools 0.143.22 → 0.143.24
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/{chunk-SX4FMBR4.js → chunk-4OCJWLGM.js} +48 -48
- package/dist/{chunk-INGOZELS.js → chunk-6AQ4XKGN.js} +8 -8
- package/dist/{chunk-NTSC46IQ.mjs → chunk-EWU6VZ32.mjs} +1 -1
- package/dist/{chunk-Z424F4SY.mjs → chunk-KGIBCAXS.mjs} +4 -4
- package/dist/{chunk-O4QVCGZS.mjs → chunk-LKJRVI3T.mjs} +2 -2
- package/dist/{chunk-XKPVTPMQ.js → chunk-MDHASPY4.js} +13 -13
- package/dist/{chunk-XCPCKIUW.js → chunk-MITAVBMN.js} +8 -8
- package/dist/{chunk-MCFSUUJG.mjs → chunk-O3AMZWYF.mjs} +1 -1
- package/dist/{chunk-H64CZVJJ.js → chunk-PJ6US7XN.js} +10 -6
- package/dist/{chunk-PUP2YY6V.mjs → chunk-Q7NQEIUF.mjs} +9 -9
- package/dist/{chunk-3WFCBFRM.mjs → chunk-UNLRQN2S.mjs} +6 -2
- package/dist/{chunk-INX6NBKW.js → chunk-US6NZ6IW.js} +2 -2
- package/dist/{chunk-L6FYW3ID.js → chunk-XQSNXFPQ.js} +2 -2
- package/dist/{chunk-B5EAYIOT.mjs → chunk-YUZ6Q34B.mjs} +1 -1
- package/dist/index.d.mts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +8 -8
- package/dist/index.mjs +7 -7
- package/dist/plugins/analyze.js +3 -3
- package/dist/plugins/analyze.mjs +2 -2
- package/dist/plugins/index.js +4 -4
- package/dist/plugins/index.mjs +3 -3
- package/dist/plugins/ts-resolve.js +3 -3
- package/dist/plugins/ts-resolve.mjs +2 -2
- package/dist/{types-BOD8Yftb.d.mts → types-B6HfHepu.d.mts} +21 -5
- package/dist/{types-BOD8Yftb.d.ts → types-B6HfHepu.d.ts} +21 -5
- package/dist/types.d.mts +2 -2
- package/dist/types.d.ts +2 -2
- package/dist/utilities/copy-assets.d.mts +2 -2
- package/dist/utilities/copy-assets.d.ts +2 -2
- package/dist/utilities/copy-assets.js +3 -3
- package/dist/utilities/copy-assets.mjs +2 -2
- package/dist/utilities/generate-package-json.d.mts +2 -2
- package/dist/utilities/generate-package-json.d.ts +2 -2
- package/dist/utilities/generate-package-json.js +3 -3
- package/dist/utilities/generate-package-json.mjs +2 -2
- package/dist/utilities/get-entry-points.d.mts +2 -2
- package/dist/utilities/get-entry-points.d.ts +2 -2
- package/dist/utilities/get-entry-points.js +3 -3
- package/dist/utilities/get-entry-points.mjs +2 -2
- package/dist/utilities/get-env.d.mts +1 -1
- package/dist/utilities/get-env.d.ts +1 -1
- package/dist/utilities/index.d.mts +1 -1
- package/dist/utilities/index.d.ts +1 -1
- package/dist/utilities/index.js +6 -6
- package/dist/utilities/index.mjs +5 -5
- package/dist/utilities/read-nx-config.js +3 -3
- package/dist/utilities/read-nx-config.mjs +2 -2
- package/package.json +1 -1
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 -->
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
|
|
15
15
|
|
|
16
16
|
|
|
17
|
-
var
|
|
17
|
+
var _chunkUS6NZ6IWjs = require('./chunk-US6NZ6IW.js');
|
|
18
18
|
|
|
19
19
|
|
|
20
20
|
var _chunkSHUYVCIDjs = require('./chunk-SHUYVCID.js');
|
|
@@ -23,7 +23,7 @@ var _chunkSHUYVCIDjs = require('./chunk-SHUYVCID.js');
|
|
|
23
23
|
var _c12 = require('c12');
|
|
24
24
|
var _defu = require('defu'); var _defu2 = _interopRequireDefault(_defu);
|
|
25
25
|
var getConfigFileByName = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0, async (fileName, filePath, options = {}) => {
|
|
26
|
-
const workspacePath = filePath ||
|
|
26
|
+
const workspacePath = filePath || _chunkUS6NZ6IWjs.findWorkspaceRoot.call(void 0, filePath);
|
|
27
27
|
const configs = await Promise.all([
|
|
28
28
|
_c12.loadConfig.call(void 0, {
|
|
29
29
|
cwd: workspacePath,
|
|
@@ -32,7 +32,7 @@ var getConfigFileByName = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0, a
|
|
|
32
32
|
envName: _optionalChain([fileName, 'optionalAccess', _ => _.toUpperCase, 'call', _2 => _2()]),
|
|
33
33
|
jitiOptions: {
|
|
34
34
|
debug: false,
|
|
35
|
-
fsCache: process.env.STORM_SKIP_CACHE === "true" ? false :
|
|
35
|
+
fsCache: process.env.STORM_SKIP_CACHE === "true" ? false : _chunkUS6NZ6IWjs.joinPaths.call(void 0, process.env.STORM_CACHE_DIR || "node_modules/.cache/storm", "jiti")
|
|
36
36
|
},
|
|
37
37
|
...options
|
|
38
38
|
}),
|
|
@@ -43,7 +43,7 @@ var getConfigFileByName = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0, a
|
|
|
43
43
|
envName: _optionalChain([fileName, 'optionalAccess', _3 => _3.toUpperCase, 'call', _4 => _4()]),
|
|
44
44
|
jitiOptions: {
|
|
45
45
|
debug: false,
|
|
46
|
-
fsCache: process.env.STORM_SKIP_CACHE === "true" ? false :
|
|
46
|
+
fsCache: process.env.STORM_SKIP_CACHE === "true" ? false : _chunkUS6NZ6IWjs.joinPaths.call(void 0, process.env.STORM_CACHE_DIR || "node_modules/.cache/storm", "jiti")
|
|
47
47
|
},
|
|
48
48
|
configFile: fileName,
|
|
49
49
|
...options
|
|
@@ -52,12 +52,12 @@ var getConfigFileByName = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0, a
|
|
|
52
52
|
return _defu2.default.call(void 0, _nullishCoalesce(configs[0], () => ( {})), _nullishCoalesce(configs[1], () => ( {})));
|
|
53
53
|
}, "getConfigFileByName");
|
|
54
54
|
var getConfigFile = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0, async (filePath, additionalFileNames = []) => {
|
|
55
|
-
const workspacePath = filePath ? filePath :
|
|
55
|
+
const workspacePath = filePath ? filePath : _chunkUS6NZ6IWjs.findWorkspaceRoot.call(void 0, filePath);
|
|
56
56
|
const result = await getConfigFileByName("storm-workspace", workspacePath);
|
|
57
57
|
let config = result.config;
|
|
58
58
|
const configFile = result.configFile;
|
|
59
59
|
if (config && configFile && Object.keys(config).length > 0 && !config.skipConfigLogging) {
|
|
60
|
-
|
|
60
|
+
_chunkUS6NZ6IWjs.writeTrace.call(void 0, `Found Storm configuration file "${configFile.includes(`${workspacePath}/`) ? configFile.replace(`${workspacePath}/`, "") : configFile}" at "${workspacePath}"`, {
|
|
61
61
|
logLevel: "all"
|
|
62
62
|
});
|
|
63
63
|
}
|
|
@@ -66,7 +66,7 @@ var getConfigFile = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0, async (
|
|
|
66
66
|
for (const result2 of results) {
|
|
67
67
|
if (_optionalChain([result2, 'optionalAccess', _5 => _5.config]) && _optionalChain([result2, 'optionalAccess', _6 => _6.configFile]) && Object.keys(result2.config).length > 0) {
|
|
68
68
|
if (!config.skipConfigLogging && !result2.config.skipConfigLogging) {
|
|
69
|
-
|
|
69
|
+
_chunkUS6NZ6IWjs.writeTrace.call(void 0, `Found alternative configuration file "${result2.configFile.includes(`${workspacePath}/`) ? result2.configFile.replace(`${workspacePath}/`, "") : result2.configFile}" at "${workspacePath}"`, {
|
|
70
70
|
logLevel: "all"
|
|
71
71
|
});
|
|
72
72
|
}
|
|
@@ -128,15 +128,15 @@ var getConfigEnv = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0, () => {
|
|
|
128
128
|
contact: process.env[`${prefix}CONTACT`] || void 0,
|
|
129
129
|
timezone: process.env[`${prefix}TIMEZONE`] || process.env.TZ || void 0,
|
|
130
130
|
locale: process.env[`${prefix}LOCALE`] || process.env.LOCALE || void 0,
|
|
131
|
-
configFile: process.env[`${prefix}CONFIG_FILE`] ?
|
|
132
|
-
workspaceRoot: process.env[`${prefix}WORKSPACE_ROOT`] ?
|
|
131
|
+
configFile: process.env[`${prefix}CONFIG_FILE`] ? _chunkUS6NZ6IWjs.correctPaths.call(void 0, process.env[`${prefix}CONFIG_FILE`]) : void 0,
|
|
132
|
+
workspaceRoot: process.env[`${prefix}WORKSPACE_ROOT`] ? _chunkUS6NZ6IWjs.correctPaths.call(void 0, process.env[`${prefix}WORKSPACE_ROOT`]) : void 0,
|
|
133
133
|
directories: {
|
|
134
|
-
cache: process.env[`${prefix}CACHE_DIR`] ?
|
|
135
|
-
data: process.env[`${prefix}DATA_DIR`] ?
|
|
136
|
-
config: process.env[`${prefix}CONFIG_DIR`] ?
|
|
137
|
-
temp: process.env[`${prefix}TEMP_DIR`] ?
|
|
138
|
-
log: process.env[`${prefix}LOG_DIR`] ?
|
|
139
|
-
build: process.env[`${prefix}BUILD_DIR`] ?
|
|
134
|
+
cache: process.env[`${prefix}CACHE_DIR`] ? _chunkUS6NZ6IWjs.correctPaths.call(void 0, process.env[`${prefix}CACHE_DIR`]) : void 0,
|
|
135
|
+
data: process.env[`${prefix}DATA_DIR`] ? _chunkUS6NZ6IWjs.correctPaths.call(void 0, process.env[`${prefix}DATA_DIR`]) : void 0,
|
|
136
|
+
config: process.env[`${prefix}CONFIG_DIR`] ? _chunkUS6NZ6IWjs.correctPaths.call(void 0, process.env[`${prefix}CONFIG_DIR`]) : void 0,
|
|
137
|
+
temp: process.env[`${prefix}TEMP_DIR`] ? _chunkUS6NZ6IWjs.correctPaths.call(void 0, process.env[`${prefix}TEMP_DIR`]) : void 0,
|
|
138
|
+
log: process.env[`${prefix}LOG_DIR`] ? _chunkUS6NZ6IWjs.correctPaths.call(void 0, process.env[`${prefix}LOG_DIR`]) : void 0,
|
|
139
|
+
build: process.env[`${prefix}BUILD_DIR`] ? _chunkUS6NZ6IWjs.correctPaths.call(void 0, process.env[`${prefix}BUILD_DIR`]) : void 0
|
|
140
140
|
},
|
|
141
141
|
skipCache: process.env[`${prefix}SKIP_CACHE`] !== void 0 ? Boolean(process.env[`${prefix}SKIP_CACHE`]) : void 0,
|
|
142
142
|
mode: (_nullishCoalesce(_nullishCoalesce(process.env[`${prefix}MODE`], () => ( process.env.NODE_ENV)), () => ( process.env.ENVIRONMENT))) || void 0,
|
|
@@ -159,24 +159,24 @@ var getConfigEnv = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0, () => {
|
|
|
159
159
|
cyclone: process.env[`${prefix}REGISTRY_CYCLONE`] || void 0,
|
|
160
160
|
container: process.env[`${prefix}REGISTRY_CONTAINER`] || void 0
|
|
161
161
|
},
|
|
162
|
-
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`])) ?
|
|
162
|
+
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`])) ? _chunkUS6NZ6IWjs.getLogLevelLabel.call(void 0, Number.parseInt(process.env[`${prefix}LOG_LEVEL`])) : process.env[`${prefix}LOG_LEVEL`] : void 0,
|
|
163
163
|
skipConfigLogging: process.env[`${prefix}SKIP_CONFIG_LOGGING`] !== void 0 ? Boolean(process.env[`${prefix}SKIP_CONFIG_LOGGING`]) : void 0
|
|
164
164
|
};
|
|
165
|
-
const themeNames = Object.keys(process.env).filter((envKey) => envKey.startsWith(`${prefix}COLOR_`) &&
|
|
165
|
+
const themeNames = Object.keys(process.env).filter((envKey) => envKey.startsWith(`${prefix}COLOR_`) && _chunkUS6NZ6IWjs.COLOR_KEYS.every((colorKey) => !envKey.startsWith(`${prefix}COLOR_LIGHT_${colorKey}`) && !envKey.startsWith(`${prefix}COLOR_DARK_${colorKey}`)));
|
|
166
166
|
config.colors = themeNames.length > 0 ? themeNames.reduce((ret, themeName) => {
|
|
167
167
|
ret[themeName] = getThemeColorConfigEnv(prefix, themeName);
|
|
168
168
|
return ret;
|
|
169
169
|
}, {}) : getThemeColorConfigEnv(prefix);
|
|
170
|
-
if (config.docs ===
|
|
171
|
-
if (config.homepage ===
|
|
172
|
-
config.docs = `${
|
|
170
|
+
if (config.docs === _chunkUS6NZ6IWjs.STORM_DEFAULT_DOCS) {
|
|
171
|
+
if (config.homepage === _chunkUS6NZ6IWjs.STORM_DEFAULT_HOMEPAGE) {
|
|
172
|
+
config.docs = `${_chunkUS6NZ6IWjs.STORM_DEFAULT_HOMEPAGE}/projects/${config.name}/docs`;
|
|
173
173
|
} else {
|
|
174
174
|
config.docs = `${config.homepage}/docs`;
|
|
175
175
|
}
|
|
176
176
|
}
|
|
177
|
-
if (config.licensing ===
|
|
178
|
-
if (config.homepage ===
|
|
179
|
-
config.licensing = `${
|
|
177
|
+
if (config.licensing === _chunkUS6NZ6IWjs.STORM_DEFAULT_LICENSING) {
|
|
178
|
+
if (config.homepage === _chunkUS6NZ6IWjs.STORM_DEFAULT_HOMEPAGE) {
|
|
179
|
+
config.licensing = `${_chunkUS6NZ6IWjs.STORM_DEFAULT_HOMEPAGE}/projects/${config.name}/licensing`;
|
|
180
180
|
} else {
|
|
181
181
|
config.licensing = `${config.homepage}/docs`;
|
|
182
182
|
}
|
|
@@ -342,31 +342,31 @@ var setConfigEnv = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0, (config)
|
|
|
342
342
|
process.env.LANG = config.locale ? `${config.locale.replaceAll("-", "_")}.UTF-8` : "en_US.UTF-8";
|
|
343
343
|
}
|
|
344
344
|
if (config.configFile) {
|
|
345
|
-
process.env[`${prefix}CONFIG_FILE`] =
|
|
345
|
+
process.env[`${prefix}CONFIG_FILE`] = _chunkUS6NZ6IWjs.correctPaths.call(void 0, config.configFile);
|
|
346
346
|
}
|
|
347
347
|
if (config.workspaceRoot) {
|
|
348
|
-
process.env[`${prefix}WORKSPACE_ROOT`] =
|
|
349
|
-
process.env.NX_WORKSPACE_ROOT =
|
|
350
|
-
process.env.NX_WORKSPACE_ROOT_PATH =
|
|
348
|
+
process.env[`${prefix}WORKSPACE_ROOT`] = _chunkUS6NZ6IWjs.correctPaths.call(void 0, config.workspaceRoot);
|
|
349
|
+
process.env.NX_WORKSPACE_ROOT = _chunkUS6NZ6IWjs.correctPaths.call(void 0, config.workspaceRoot);
|
|
350
|
+
process.env.NX_WORKSPACE_ROOT_PATH = _chunkUS6NZ6IWjs.correctPaths.call(void 0, config.workspaceRoot);
|
|
351
351
|
}
|
|
352
352
|
if (config.directories) {
|
|
353
353
|
if (!config.skipCache && config.directories.cache) {
|
|
354
|
-
process.env[`${prefix}CACHE_DIR`] =
|
|
354
|
+
process.env[`${prefix}CACHE_DIR`] = _chunkUS6NZ6IWjs.correctPaths.call(void 0, config.directories.cache);
|
|
355
355
|
}
|
|
356
356
|
if (config.directories.data) {
|
|
357
|
-
process.env[`${prefix}DATA_DIR`] =
|
|
357
|
+
process.env[`${prefix}DATA_DIR`] = _chunkUS6NZ6IWjs.correctPaths.call(void 0, config.directories.data);
|
|
358
358
|
}
|
|
359
359
|
if (config.directories.config) {
|
|
360
|
-
process.env[`${prefix}CONFIG_DIR`] =
|
|
360
|
+
process.env[`${prefix}CONFIG_DIR`] = _chunkUS6NZ6IWjs.correctPaths.call(void 0, config.directories.config);
|
|
361
361
|
}
|
|
362
362
|
if (config.directories.temp) {
|
|
363
|
-
process.env[`${prefix}TEMP_DIR`] =
|
|
363
|
+
process.env[`${prefix}TEMP_DIR`] = _chunkUS6NZ6IWjs.correctPaths.call(void 0, config.directories.temp);
|
|
364
364
|
}
|
|
365
365
|
if (config.directories.log) {
|
|
366
|
-
process.env[`${prefix}LOG_DIR`] =
|
|
366
|
+
process.env[`${prefix}LOG_DIR`] = _chunkUS6NZ6IWjs.correctPaths.call(void 0, config.directories.log);
|
|
367
367
|
}
|
|
368
368
|
if (config.directories.build) {
|
|
369
|
-
process.env[`${prefix}BUILD_DIR`] =
|
|
369
|
+
process.env[`${prefix}BUILD_DIR`] = _chunkUS6NZ6IWjs.correctPaths.call(void 0, config.directories.build);
|
|
370
370
|
}
|
|
371
371
|
}
|
|
372
372
|
if (config.skipCache !== void 0) {
|
|
@@ -420,8 +420,8 @@ var setConfigEnv = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0, (config)
|
|
|
420
420
|
if (config.logLevel) {
|
|
421
421
|
process.env[`${prefix}LOG_LEVEL`] = String(config.logLevel);
|
|
422
422
|
process.env.LOG_LEVEL = String(config.logLevel);
|
|
423
|
-
process.env.NX_VERBOSE_LOGGING = String(
|
|
424
|
-
process.env.RUST_BACKTRACE =
|
|
423
|
+
process.env.NX_VERBOSE_LOGGING = String(_chunkUS6NZ6IWjs.getLogLevel.call(void 0, config.logLevel) >= _chunkUS6NZ6IWjs.LogLevel.DEBUG ? true : false);
|
|
424
|
+
process.env.RUST_BACKTRACE = _chunkUS6NZ6IWjs.getLogLevel.call(void 0, config.logLevel) >= _chunkUS6NZ6IWjs.LogLevel.DEBUG ? "full" : "none";
|
|
425
425
|
}
|
|
426
426
|
if (config.skipConfigLogging !== void 0) {
|
|
427
427
|
process.env[`${prefix}SKIP_CONFIG_LOGGING`] = String(config.skipConfigLogging);
|
|
@@ -534,22 +534,22 @@ var setBaseThemeColorConfigEnv = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(vo
|
|
|
534
534
|
// ../config-tools/src/create-storm-config.ts
|
|
535
535
|
var _extension_cache = /* @__PURE__ */ new WeakMap();
|
|
536
536
|
var _static_cache = void 0;
|
|
537
|
-
var
|
|
537
|
+
var createStormWorkspaceConfig = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0, async (extensionName, schema, workspaceRoot, skipLogs = false) => {
|
|
538
538
|
let result;
|
|
539
539
|
if (!_optionalChain([_static_cache, 'optionalAccess', _29 => _29.data]) || !_optionalChain([_static_cache, 'optionalAccess', _30 => _30.timestamp]) || _static_cache.timestamp < Date.now() - 8e3) {
|
|
540
540
|
let _workspaceRoot = workspaceRoot;
|
|
541
541
|
if (!_workspaceRoot) {
|
|
542
|
-
_workspaceRoot =
|
|
542
|
+
_workspaceRoot = _chunkUS6NZ6IWjs.findWorkspaceRoot.call(void 0, );
|
|
543
543
|
}
|
|
544
544
|
const configEnv = getConfigEnv();
|
|
545
|
-
const defaultConfig = await
|
|
545
|
+
const defaultConfig = await _chunkUS6NZ6IWjs.getDefaultConfig.call(void 0, _workspaceRoot);
|
|
546
546
|
const configFile = await getConfigFile(_workspaceRoot);
|
|
547
547
|
if (!configFile && !skipLogs) {
|
|
548
|
-
|
|
548
|
+
_chunkUS6NZ6IWjs.writeWarning.call(void 0, "No Storm Workspace configuration file found in the current repository. Please ensure this is the expected behavior - you can add a `storm-workspace.json` file to the root of your workspace if it is not.\n", {
|
|
549
549
|
logLevel: "all"
|
|
550
550
|
});
|
|
551
551
|
}
|
|
552
|
-
result = await
|
|
552
|
+
result = await _chunkUS6NZ6IWjs.stormWorkspaceConfigSchema.parseAsync(_defu2.default.call(void 0, configEnv, configFile, defaultConfig));
|
|
553
553
|
result.workspaceRoot ??= _workspaceRoot;
|
|
554
554
|
} else {
|
|
555
555
|
result = _static_cache.data;
|
|
@@ -565,7 +565,7 @@ var createStormConfig = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0, asy
|
|
|
565
565
|
data: result
|
|
566
566
|
};
|
|
567
567
|
return result;
|
|
568
|
-
}, "
|
|
568
|
+
}, "createStormWorkspaceConfig");
|
|
569
569
|
var createConfigExtension = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0, (extensionName, schema) => {
|
|
570
570
|
const extension_cache_key = {
|
|
571
571
|
extensionName
|
|
@@ -580,19 +580,19 @@ var createConfigExtension = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0,
|
|
|
580
580
|
_extension_cache.set(extension_cache_key, extension);
|
|
581
581
|
return extension;
|
|
582
582
|
}, "createConfigExtension");
|
|
583
|
-
var
|
|
584
|
-
const config = await
|
|
583
|
+
var loadStormWorkspaceConfig = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0, async (workspaceRoot, skipLogs = false) => {
|
|
584
|
+
const config = await createStormWorkspaceConfig(void 0, void 0, workspaceRoot, skipLogs);
|
|
585
585
|
setConfigEnv(config);
|
|
586
586
|
if (!skipLogs && !config.skipConfigLogging) {
|
|
587
|
-
|
|
588
|
-
${
|
|
587
|
+
_chunkUS6NZ6IWjs.writeTrace.call(void 0, `\u2699\uFE0F Using Storm Workspace configuration:
|
|
588
|
+
${_chunkUS6NZ6IWjs.formatLogMessage.call(void 0, config)}`, config);
|
|
589
589
|
}
|
|
590
590
|
return config;
|
|
591
|
-
}, "
|
|
591
|
+
}, "loadStormWorkspaceConfig");
|
|
592
592
|
|
|
593
593
|
// ../config-tools/src/get-config.ts
|
|
594
594
|
var getConfig = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0, (workspaceRoot, skipLogs = false) => {
|
|
595
|
-
return
|
|
595
|
+
return loadStormWorkspaceConfig(workspaceRoot, skipLogs);
|
|
596
596
|
}, "getConfig");
|
|
597
597
|
|
|
598
598
|
// src/utilities/read-nx-config.ts
|
|
@@ -604,7 +604,7 @@ var readNxConfig = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0, async (w
|
|
|
604
604
|
const config = await getConfig();
|
|
605
605
|
rootDir = config.workspaceRoot;
|
|
606
606
|
}
|
|
607
|
-
const nxJsonPath =
|
|
607
|
+
const nxJsonPath = _chunkUS6NZ6IWjs.joinPaths.call(void 0, rootDir, "nx.json");
|
|
608
608
|
if (!_fs.existsSync.call(void 0, nxJsonPath)) {
|
|
609
609
|
throw new Error("Cannot find project.json configuration");
|
|
610
610
|
}
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
|
|
4
4
|
|
|
5
|
-
var
|
|
5
|
+
var _chunkUS6NZ6IWjs = require('./chunk-US6NZ6IW.js');
|
|
6
6
|
|
|
7
7
|
|
|
8
8
|
var _chunkSHUYVCIDjs = require('./chunk-SHUYVCID.js');
|
|
@@ -37,8 +37,8 @@ var copyAssets = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0, async (con
|
|
|
37
37
|
output: "src/"
|
|
38
38
|
});
|
|
39
39
|
}
|
|
40
|
-
|
|
41
|
-
${pendingAssets.map((pendingAsset) => typeof pendingAsset === "string" ? ` - ${pendingAsset} -> ${outputPath}` : ` - ${pendingAsset.input}/${pendingAsset.glob} -> ${
|
|
40
|
+
_chunkUS6NZ6IWjs.writeTrace.call(void 0, `\u{1F4DD} Copying the following assets to the output directory:
|
|
41
|
+
${pendingAssets.map((pendingAsset) => typeof pendingAsset === "string" ? ` - ${pendingAsset} -> ${outputPath}` : ` - ${pendingAsset.input}/${pendingAsset.glob} -> ${_chunkUS6NZ6IWjs.joinPaths.call(void 0, outputPath, pendingAsset.output)}`).join("\n")}`, config);
|
|
42
42
|
const assetHandler = new (0, _copyassetshandler.CopyAssetsHandler)({
|
|
43
43
|
projectDir: projectRoot,
|
|
44
44
|
rootDir: config.workspaceRoot,
|
|
@@ -47,12 +47,12 @@ ${pendingAssets.map((pendingAsset) => typeof pendingAsset === "string" ? ` - ${p
|
|
|
47
47
|
});
|
|
48
48
|
await assetHandler.processAllAssetsOnce();
|
|
49
49
|
if (includeSrc === true) {
|
|
50
|
-
|
|
50
|
+
_chunkUS6NZ6IWjs.writeDebug.call(void 0, `\u{1F4DD} Adding banner and writing source files: ${_chunkUS6NZ6IWjs.joinPaths.call(void 0, outputPath, "src")}`, config);
|
|
51
51
|
const files = await _glob.glob.call(void 0, [
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
52
|
+
_chunkUS6NZ6IWjs.joinPaths.call(void 0, config.workspaceRoot, outputPath, "src/**/*.ts"),
|
|
53
|
+
_chunkUS6NZ6IWjs.joinPaths.call(void 0, config.workspaceRoot, outputPath, "src/**/*.tsx"),
|
|
54
|
+
_chunkUS6NZ6IWjs.joinPaths.call(void 0, config.workspaceRoot, outputPath, "src/**/*.js"),
|
|
55
|
+
_chunkUS6NZ6IWjs.joinPaths.call(void 0, config.workspaceRoot, outputPath, "src/**/*.jsx")
|
|
56
56
|
]);
|
|
57
57
|
await Promise.allSettled(files.map(async (file) => _promises.writeFile.call(void 0, file, `${banner && typeof banner === "string" ? banner.startsWith("//") ? banner : `// ${banner}` : ""}
|
|
58
58
|
|
|
@@ -2,7 +2,7 @@ import {
|
|
|
2
2
|
findWorkspaceRoot,
|
|
3
3
|
joinPaths,
|
|
4
4
|
writeTrace
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-LKJRVI3T.mjs";
|
|
6
6
|
import {
|
|
7
7
|
__name
|
|
8
8
|
} from "./chunk-O6YSETKJ.mjs";
|
|
@@ -53,13 +53,13 @@ var addPackageDependencies = /* @__PURE__ */ __name(async (workspaceRoot, projec
|
|
|
53
53
|
return ret;
|
|
54
54
|
}, []);
|
|
55
55
|
packageJson.dependencies = localPackages.reduce((ret, localPackage) => {
|
|
56
|
-
if (!ret[localPackage.name] && !implicitDependencies?.includes(localPackage.name)) {
|
|
57
|
-
ret[localPackage.name] =
|
|
56
|
+
if (!ret[localPackage.name] && !implicitDependencies?.includes(localPackage.name) && packageJson.devDependencies?.[localPackage.name] === void 0) {
|
|
57
|
+
ret[localPackage.name] = `^${localPackage.version || "0.0.1"}`;
|
|
58
58
|
}
|
|
59
59
|
return ret;
|
|
60
60
|
}, packageJson.dependencies ?? {});
|
|
61
61
|
packageJson.devDependencies = localPackages.reduce((ret, localPackage) => {
|
|
62
|
-
if (!ret[localPackage.name] && implicitDependencies?.includes(localPackage.name)) {
|
|
62
|
+
if (!ret[localPackage.name] && implicitDependencies?.includes(localPackage.name) && packageJson.dependencies?.[localPackage.name] === void 0) {
|
|
63
63
|
ret[localPackage.name] = localPackage.version || "0.0.1";
|
|
64
64
|
}
|
|
65
65
|
return ret;
|
|
@@ -366,7 +366,7 @@ var WorkspaceDirectoryConfigSchema = z.object({
|
|
|
366
366
|
log: z.string().trim().optional().describe("The directory used to store the environment's temp files"),
|
|
367
367
|
build: z.string().trim().default("dist").describe("The directory used to store the workspace's distributable files after a build (relative to the workspace root)")
|
|
368
368
|
}).describe("Various directories used by the workspace to store data, cache, and configuration files");
|
|
369
|
-
var
|
|
369
|
+
var stormWorkspaceConfigSchema = z.object({
|
|
370
370
|
$schema: z.string().trim().default("https://cdn.jsdelivr.net/npm/@storm-software/config/schemas/storm-workspace.schema.json").optional().nullish().describe("The URL to the JSON schema file that describes the Storm configuration file"),
|
|
371
371
|
extends: ExtendsSchema.optional(),
|
|
372
372
|
name: z.string().trim().toLowerCase().optional().describe("The name of the service/package/scope using this configuration"),
|
|
@@ -721,7 +721,7 @@ export {
|
|
|
721
721
|
STORM_DEFAULT_DOCS,
|
|
722
722
|
STORM_DEFAULT_HOMEPAGE,
|
|
723
723
|
STORM_DEFAULT_LICENSING,
|
|
724
|
-
|
|
724
|
+
stormWorkspaceConfigSchema,
|
|
725
725
|
COLOR_KEYS,
|
|
726
726
|
correctPaths,
|
|
727
727
|
joinPaths,
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
|
|
4
4
|
|
|
5
|
-
var
|
|
5
|
+
var _chunkUS6NZ6IWjs = require('./chunk-US6NZ6IW.js');
|
|
6
6
|
|
|
7
7
|
|
|
8
8
|
var _chunkSHUYVCIDjs = require('./chunk-SHUYVCID.js');
|
|
@@ -20,7 +20,7 @@ var addPackageDependencies = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0
|
|
|
20
20
|
for (const project of projectDependencies.dependencies.filter((dep) => dep.node.type === "lib" && _optionalChain([dep, 'access', _ => _.node, 'access', _2 => _2.data, 'optionalAccess', _3 => _3.root]) !== projectRoot && _optionalChain([dep, 'access', _4 => _4.node, 'access', _5 => _5.data, 'optionalAccess', _6 => _6.root]) !== workspaceRoot)) {
|
|
21
21
|
const projectNode = project.node;
|
|
22
22
|
if (projectNode.data.root) {
|
|
23
|
-
const projectPackageJsonPath =
|
|
23
|
+
const projectPackageJsonPath = _chunkUS6NZ6IWjs.joinPaths.call(void 0, workspaceRoot, projectNode.data.root, "package.json");
|
|
24
24
|
if (_fs.existsSync.call(void 0, projectPackageJsonPath)) {
|
|
25
25
|
const projectPackageJsonContent = await _promises.readFile.call(void 0, projectPackageJsonPath, "utf8");
|
|
26
26
|
const projectPackageJson = JSON.parse(projectPackageJsonContent);
|
|
@@ -31,8 +31,8 @@ var addPackageDependencies = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0
|
|
|
31
31
|
}
|
|
32
32
|
}
|
|
33
33
|
if (localPackages.length > 0) {
|
|
34
|
-
|
|
35
|
-
const projectJsonFile = await _promises.readFile.call(void 0,
|
|
34
|
+
_chunkUS6NZ6IWjs.writeTrace.call(void 0, `\u{1F4E6} Adding local packages to package.json: ${localPackages.map((p) => p.name).join(", ")}`);
|
|
35
|
+
const projectJsonFile = await _promises.readFile.call(void 0, _chunkUS6NZ6IWjs.joinPaths.call(void 0, projectRoot, "project.json"), "utf8");
|
|
36
36
|
const projectJson = JSON.parse(projectJsonFile);
|
|
37
37
|
const projectName2 = projectJson.name;
|
|
38
38
|
const projectConfigurations = _projectgraph.readProjectsConfigurationFromProjectGraph.call(void 0, projectGraph);
|
|
@@ -41,7 +41,7 @@ var addPackageDependencies = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0
|
|
|
41
41
|
}
|
|
42
42
|
const implicitDependencies = _optionalChain([projectConfigurations, 'access', _9 => _9.projects, 'optionalAccess', _10 => _10[projectName2], 'access', _11 => _11.implicitDependencies, 'optionalAccess', _12 => _12.reduce, 'call', _13 => _13((ret, dep) => {
|
|
43
43
|
if (_optionalChain([projectConfigurations, 'access', _14 => _14.projects, 'optionalAccess', _15 => _15[dep]])) {
|
|
44
|
-
const depPackageJsonPath =
|
|
44
|
+
const depPackageJsonPath = _chunkUS6NZ6IWjs.joinPaths.call(void 0, workspaceRoot, projectConfigurations.projects[dep].root, "package.json");
|
|
45
45
|
if (_fs.existsSync.call(void 0, depPackageJsonPath)) {
|
|
46
46
|
const depPackageJsonContent = _fs.readFileSync.call(void 0, depPackageJsonPath, "utf8");
|
|
47
47
|
const depPackageJson = JSON.parse(depPackageJsonContent);
|
|
@@ -53,25 +53,25 @@ var addPackageDependencies = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0
|
|
|
53
53
|
return ret;
|
|
54
54
|
}, [])]);
|
|
55
55
|
packageJson.dependencies = localPackages.reduce((ret, localPackage) => {
|
|
56
|
-
if (!ret[localPackage.name] && !_optionalChain([implicitDependencies, 'optionalAccess', _16 => _16.includes, 'call', _17 => _17(localPackage.name)])) {
|
|
57
|
-
ret[localPackage.name] =
|
|
56
|
+
if (!ret[localPackage.name] && !_optionalChain([implicitDependencies, 'optionalAccess', _16 => _16.includes, 'call', _17 => _17(localPackage.name)]) && _optionalChain([packageJson, 'access', _18 => _18.devDependencies, 'optionalAccess', _19 => _19[localPackage.name]]) === void 0) {
|
|
57
|
+
ret[localPackage.name] = `^${localPackage.version || "0.0.1"}`;
|
|
58
58
|
}
|
|
59
59
|
return ret;
|
|
60
60
|
}, _nullishCoalesce(packageJson.dependencies, () => ( {})));
|
|
61
61
|
packageJson.devDependencies = localPackages.reduce((ret, localPackage) => {
|
|
62
|
-
if (!ret[localPackage.name] && _optionalChain([implicitDependencies, 'optionalAccess',
|
|
62
|
+
if (!ret[localPackage.name] && _optionalChain([implicitDependencies, 'optionalAccess', _20 => _20.includes, 'call', _21 => _21(localPackage.name)]) && _optionalChain([packageJson, 'access', _22 => _22.dependencies, 'optionalAccess', _23 => _23[localPackage.name]]) === void 0) {
|
|
63
63
|
ret[localPackage.name] = localPackage.version || "0.0.1";
|
|
64
64
|
}
|
|
65
65
|
return ret;
|
|
66
66
|
}, _nullishCoalesce(packageJson.devDependencies, () => ( {})));
|
|
67
67
|
} else {
|
|
68
|
-
|
|
68
|
+
_chunkUS6NZ6IWjs.writeTrace.call(void 0, "\u{1F4E6} No local packages dependencies to add to package.json");
|
|
69
69
|
}
|
|
70
70
|
return packageJson;
|
|
71
71
|
}, "addPackageDependencies");
|
|
72
72
|
var addWorkspacePackageJsonFields = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0, async (config, projectRoot, sourceRoot, projectName, includeSrc = false, packageJson) => {
|
|
73
|
-
const workspaceRoot = config.workspaceRoot ? config.workspaceRoot :
|
|
74
|
-
const workspacePackageJsonContent = await _promises.readFile.call(void 0,
|
|
73
|
+
const workspaceRoot = config.workspaceRoot ? config.workspaceRoot : _chunkUS6NZ6IWjs.findWorkspaceRoot.call(void 0, );
|
|
74
|
+
const workspacePackageJsonContent = await _promises.readFile.call(void 0, _chunkUS6NZ6IWjs.joinPaths.call(void 0, workspaceRoot, "package.json"), "utf8");
|
|
75
75
|
const workspacePackageJson = JSON.parse(workspacePackageJsonContent);
|
|
76
76
|
packageJson.type ??= "module";
|
|
77
77
|
packageJson.sideEffects ??= false;
|
|
@@ -80,7 +80,7 @@ var addWorkspacePackageJsonFields = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call
|
|
|
80
80
|
if (distSrc.startsWith("/")) {
|
|
81
81
|
distSrc = distSrc.substring(1);
|
|
82
82
|
}
|
|
83
|
-
packageJson.source ??= `${
|
|
83
|
+
packageJson.source ??= `${_chunkUS6NZ6IWjs.joinPaths.call(void 0, distSrc, "index.ts").replaceAll("\\", "/")}`;
|
|
84
84
|
}
|
|
85
85
|
packageJson.files ??= [
|
|
86
86
|
"dist/**/*"
|
|
@@ -111,7 +111,7 @@ var addWorkspacePackageJsonFields = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call
|
|
|
111
111
|
];
|
|
112
112
|
}
|
|
113
113
|
packageJson.repository ??= workspacePackageJson.repository;
|
|
114
|
-
packageJson.repository.directory ??= projectRoot ? projectRoot :
|
|
114
|
+
packageJson.repository.directory ??= projectRoot ? projectRoot : _chunkUS6NZ6IWjs.joinPaths.call(void 0, "packages", projectName);
|
|
115
115
|
return packageJson;
|
|
116
116
|
}, "addWorkspacePackageJsonFields");
|
|
117
117
|
var addPackageJsonExport = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0, (file, type = "module", sourceRoot) => {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } 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
|
|
3
|
+
var _chunkUS6NZ6IWjs = require('./chunk-US6NZ6IW.js');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
var _chunkSHUYVCIDjs = require('./chunk-SHUYVCID.js');
|
|
@@ -29,8 +29,8 @@ var tsResolvePlugin = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0, ({ re
|
|
|
29
29
|
return {
|
|
30
30
|
name: `storm:ts-resolve`,
|
|
31
31
|
async resolveId(source, importer) {
|
|
32
|
-
|
|
33
|
-
|
|
32
|
+
_chunkUS6NZ6IWjs.writeDebug.call(void 0, `ts-resolve - resolveId source: ${source}`);
|
|
33
|
+
_chunkUS6NZ6IWjs.writeDebug.call(void 0, `ts-resolve - resolveId importer: ${importer}`);
|
|
34
34
|
if (!importer) {
|
|
35
35
|
return null;
|
|
36
36
|
}
|
|
@@ -41,7 +41,7 @@ var tsResolvePlugin = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0, ({ re
|
|
|
41
41
|
return false;
|
|
42
42
|
}
|
|
43
43
|
if (ignore && ignore(source, importer)) {
|
|
44
|
-
|
|
44
|
+
_chunkUS6NZ6IWjs.writeDebug.call(void 0, `ts-resolve - ignored ${source}`);
|
|
45
45
|
return null;
|
|
46
46
|
}
|
|
47
47
|
if (resolveOnly) {
|
|
@@ -50,12 +50,12 @@ var tsResolvePlugin = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0, ({ re
|
|
|
50
50
|
return v.test(source);
|
|
51
51
|
});
|
|
52
52
|
if (!shouldResolve) {
|
|
53
|
-
|
|
53
|
+
_chunkUS6NZ6IWjs.writeDebug.call(void 0, `ts-resolve - skipped by matching resolveOnly ${source}`);
|
|
54
54
|
return null;
|
|
55
55
|
}
|
|
56
56
|
}
|
|
57
57
|
if (_path2.default.isAbsolute(source)) {
|
|
58
|
-
|
|
58
|
+
_chunkUS6NZ6IWjs.writeDebug.call(void 0, `ts-resolve - skipped absolute path: ${source}`);
|
|
59
59
|
return null;
|
|
60
60
|
}
|
|
61
61
|
const basedir = importer ? await _fs2.default.promises.realpath(_path2.default.dirname(importer)) : process.cwd();
|
|
@@ -87,10 +87,10 @@ var tsResolvePlugin = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0, ({ re
|
|
|
87
87
|
});
|
|
88
88
|
}
|
|
89
89
|
if (id) {
|
|
90
|
-
|
|
90
|
+
_chunkUS6NZ6IWjs.writeDebug.call(void 0, `ts-resolve - resolved ${source} to ${id}`);
|
|
91
91
|
return id;
|
|
92
92
|
}
|
|
93
|
-
|
|
93
|
+
_chunkUS6NZ6IWjs.writeDebug.call(void 0, `ts-resolve - mark ${source} as external`);
|
|
94
94
|
return false;
|
|
95
95
|
}
|
|
96
96
|
};
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
var
|
|
6
|
+
var _chunkUS6NZ6IWjs = require('./chunk-US6NZ6IW.js');
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
var _chunkSHUYVCIDjs = require('./chunk-SHUYVCID.js');
|
|
@@ -11,7 +11,7 @@ var _chunkSHUYVCIDjs = require('./chunk-SHUYVCID.js');
|
|
|
11
11
|
// src/utilities/get-entry-points.ts
|
|
12
12
|
var _glob = require('glob');
|
|
13
13
|
var getEntryPoints = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0, async (config, projectRoot, sourceRoot, entry, emitOnAll = false) => {
|
|
14
|
-
const workspaceRoot = config.workspaceRoot ||
|
|
14
|
+
const workspaceRoot = config.workspaceRoot || _chunkUS6NZ6IWjs.findWorkspaceRoot.call(void 0, );
|
|
15
15
|
const entryPoints = [];
|
|
16
16
|
if (entry) {
|
|
17
17
|
if (typeof entry === "string") {
|
|
@@ -23,7 +23,7 @@ var getEntryPoints = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0, async
|
|
|
23
23
|
}
|
|
24
24
|
}
|
|
25
25
|
if (emitOnAll) {
|
|
26
|
-
entryPoints.push(
|
|
26
|
+
entryPoints.push(_chunkUS6NZ6IWjs.joinPaths.call(void 0, workspaceRoot, sourceRoot || projectRoot, "**/*.{ts,tsx}"));
|
|
27
27
|
}
|
|
28
28
|
const results = await Promise.all(entryPoints.map(async (entryPoint) => {
|
|
29
29
|
const paths = [];
|
|
@@ -35,9 +35,9 @@ var getEntryPoints = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0, async
|
|
|
35
35
|
]
|
|
36
36
|
});
|
|
37
37
|
paths.push(...files.reduce((ret, filePath) => {
|
|
38
|
-
const result =
|
|
38
|
+
const result = _chunkUS6NZ6IWjs.correctPaths.call(void 0, _chunkUS6NZ6IWjs.joinPaths.call(void 0, filePath.path, filePath.name).replaceAll(_chunkUS6NZ6IWjs.correctPaths.call(void 0, workspaceRoot), "").replaceAll(_chunkUS6NZ6IWjs.correctPaths.call(void 0, projectRoot), ""));
|
|
39
39
|
if (result) {
|
|
40
|
-
|
|
40
|
+
_chunkUS6NZ6IWjs.writeDebug.call(void 0, `Trying to add entry point ${result} at "${_chunkUS6NZ6IWjs.joinPaths.call(void 0, filePath.path, filePath.name)}"`, config);
|
|
41
41
|
if (!paths.includes(result)) {
|
|
42
42
|
paths.push(result);
|
|
43
43
|
}
|
|
@@ -45,7 +45,11 @@ var getEntryPoints = /* @__PURE__ */ _chunkSHUYVCIDjs.__name.call(void 0, async
|
|
|
45
45
|
return ret;
|
|
46
46
|
}, []));
|
|
47
47
|
} else {
|
|
48
|
-
|
|
48
|
+
const result = _chunkUS6NZ6IWjs.correctPaths.call(void 0, entryPoint.replaceAll(_chunkUS6NZ6IWjs.correctPaths.call(void 0, workspaceRoot), "").replaceAll(_chunkUS6NZ6IWjs.correctPaths.call(void 0, projectRoot), ""));
|
|
49
|
+
_chunkUS6NZ6IWjs.writeDebug.call(void 0, `Trying to add entry point ${result}"`, config);
|
|
50
|
+
if (!paths.includes(result)) {
|
|
51
|
+
paths.push(result);
|
|
52
|
+
}
|
|
49
53
|
}
|
|
50
54
|
return paths;
|
|
51
55
|
}));
|
|
@@ -4,7 +4,6 @@ import {
|
|
|
4
4
|
STORM_DEFAULT_DOCS,
|
|
5
5
|
STORM_DEFAULT_HOMEPAGE,
|
|
6
6
|
STORM_DEFAULT_LICENSING,
|
|
7
|
-
StormConfigSchema,
|
|
8
7
|
correctPaths,
|
|
9
8
|
findWorkspaceRoot,
|
|
10
9
|
formatLogMessage,
|
|
@@ -12,9 +11,10 @@ import {
|
|
|
12
11
|
getLogLevel,
|
|
13
12
|
getLogLevelLabel,
|
|
14
13
|
joinPaths,
|
|
14
|
+
stormWorkspaceConfigSchema,
|
|
15
15
|
writeTrace,
|
|
16
16
|
writeWarning
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-LKJRVI3T.mjs";
|
|
18
18
|
import {
|
|
19
19
|
__name
|
|
20
20
|
} from "./chunk-O6YSETKJ.mjs";
|
|
@@ -534,7 +534,7 @@ var setBaseThemeColorConfigEnv = /* @__PURE__ */ __name((prefix, config) => {
|
|
|
534
534
|
// ../config-tools/src/create-storm-config.ts
|
|
535
535
|
var _extension_cache = /* @__PURE__ */ new WeakMap();
|
|
536
536
|
var _static_cache = void 0;
|
|
537
|
-
var
|
|
537
|
+
var createStormWorkspaceConfig = /* @__PURE__ */ __name(async (extensionName, schema, workspaceRoot, skipLogs = false) => {
|
|
538
538
|
let result;
|
|
539
539
|
if (!_static_cache?.data || !_static_cache?.timestamp || _static_cache.timestamp < Date.now() - 8e3) {
|
|
540
540
|
let _workspaceRoot = workspaceRoot;
|
|
@@ -549,7 +549,7 @@ var createStormConfig = /* @__PURE__ */ __name(async (extensionName, schema, wor
|
|
|
549
549
|
logLevel: "all"
|
|
550
550
|
});
|
|
551
551
|
}
|
|
552
|
-
result = await
|
|
552
|
+
result = await stormWorkspaceConfigSchema.parseAsync(defu2(configEnv, configFile, defaultConfig));
|
|
553
553
|
result.workspaceRoot ??= _workspaceRoot;
|
|
554
554
|
} else {
|
|
555
555
|
result = _static_cache.data;
|
|
@@ -565,7 +565,7 @@ var createStormConfig = /* @__PURE__ */ __name(async (extensionName, schema, wor
|
|
|
565
565
|
data: result
|
|
566
566
|
};
|
|
567
567
|
return result;
|
|
568
|
-
}, "
|
|
568
|
+
}, "createStormWorkspaceConfig");
|
|
569
569
|
var createConfigExtension = /* @__PURE__ */ __name((extensionName, schema) => {
|
|
570
570
|
const extension_cache_key = {
|
|
571
571
|
extensionName
|
|
@@ -580,19 +580,19 @@ var createConfigExtension = /* @__PURE__ */ __name((extensionName, schema) => {
|
|
|
580
580
|
_extension_cache.set(extension_cache_key, extension);
|
|
581
581
|
return extension;
|
|
582
582
|
}, "createConfigExtension");
|
|
583
|
-
var
|
|
584
|
-
const config = await
|
|
583
|
+
var loadStormWorkspaceConfig = /* @__PURE__ */ __name(async (workspaceRoot, skipLogs = false) => {
|
|
584
|
+
const config = await createStormWorkspaceConfig(void 0, void 0, workspaceRoot, skipLogs);
|
|
585
585
|
setConfigEnv(config);
|
|
586
586
|
if (!skipLogs && !config.skipConfigLogging) {
|
|
587
587
|
writeTrace(`\u2699\uFE0F Using Storm Workspace configuration:
|
|
588
588
|
${formatLogMessage(config)}`, config);
|
|
589
589
|
}
|
|
590
590
|
return config;
|
|
591
|
-
}, "
|
|
591
|
+
}, "loadStormWorkspaceConfig");
|
|
592
592
|
|
|
593
593
|
// ../config-tools/src/get-config.ts
|
|
594
594
|
var getConfig = /* @__PURE__ */ __name((workspaceRoot, skipLogs = false) => {
|
|
595
|
-
return
|
|
595
|
+
return loadStormWorkspaceConfig(workspaceRoot, skipLogs);
|
|
596
596
|
}, "getConfig");
|
|
597
597
|
|
|
598
598
|
// src/utilities/read-nx-config.ts
|