@storm-software/esbuild 0.26.11 → 0.26.13
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/bin/esbuild.cjs +2 -8
- package/dist/build.cjs +8 -8
- package/dist/build.js +7 -7
- package/dist/{chunk-A7M6QDWG.cjs → chunk-3ENEOIKE.cjs} +4 -3
- package/dist/{chunk-2HAHXU54.js → chunk-4ATDIKBQ.js} +1 -1
- package/dist/{chunk-57Z7YYTW.cjs → chunk-5F7O7BRG.cjs} +33 -59
- package/dist/{chunk-VWP2SU7A.cjs → chunk-DEO4HWIA.cjs} +3 -3
- package/dist/{chunk-62KAIAWT.cjs → chunk-DITM26C7.cjs} +3 -3
- package/dist/{chunk-XZED6WF3.cjs → chunk-F665CCSS.cjs} +1 -1
- package/dist/{chunk-JOPUDEEC.cjs → chunk-H7G4L4A7.cjs} +38 -43
- package/dist/{chunk-GQQQCEJN.cjs → chunk-I2FH4C27.cjs} +2 -2
- package/dist/{chunk-F5ULKQSO.js → chunk-KFFQSANO.js} +5 -10
- package/dist/{chunk-V23YDDCC.js → chunk-LUJTYV5C.js} +3 -2
- package/dist/{chunk-7NZ2E6EC.js → chunk-NCMOSDGN.js} +1 -1
- package/dist/{chunk-DNJAV4NQ.js → chunk-TUAAYWUJ.js} +1 -1
- package/dist/{chunk-D5ZZNDUG.js → chunk-VZIK4SOK.js} +3 -29
- package/dist/{chunk-IW7GZHF7.js → chunk-YWKYHSIN.js} +1 -1
- package/dist/clean.cjs +3 -3
- package/dist/clean.js +2 -2
- package/dist/config.cjs +5 -7
- package/dist/config.d.cts +2 -3
- package/dist/config.d.ts +2 -3
- package/dist/config.js +6 -8
- package/dist/index.cjs +8 -10
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +8 -10
- package/dist/plugins/deps-check.cjs +3 -3
- package/dist/plugins/deps-check.js +2 -2
- package/dist/plugins/on-error.cjs +3 -3
- package/dist/plugins/on-error.js +2 -2
- package/dist/plugins/tsc.cjs +3 -3
- package/dist/plugins/tsc.js +2 -2
- package/dist/types.d.cts +3 -10
- package/dist/types.d.ts +3 -10
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -21,7 +21,7 @@ This package is part of the <b>⚡Storm-Ops</b> monorepo. The Storm-Ops packages
|
|
|
21
21
|
|
|
22
22
|
<h3 align="center">💻 Visit <a href="https://stormsoftware.com" target="_blank">stormsoftware.com</a> to stay up to date with this developer</h3><br />
|
|
23
23
|
|
|
24
|
-
[](https://prettier.io/) [](http://nx.dev/) [](https://nextjs.org/) [](http://commitizen.github.io/cz-cli/)  [](https://fumadocs.vercel.app/) 
|
|
25
25
|
|
|
26
26
|
<!-- prettier-ignore-start -->
|
|
27
27
|
<!-- markdownlint-disable -->
|
package/bin/esbuild.cjs
CHANGED
|
@@ -488,6 +488,7 @@ function bundleTypeDefinitions(filename, outfile, externals, options) {
|
|
|
488
488
|
overrideTsconfig: {
|
|
489
489
|
compilerOptions: {
|
|
490
490
|
paths: {}
|
|
491
|
+
// bug with api extract + paths
|
|
491
492
|
}
|
|
492
493
|
}
|
|
493
494
|
},
|
|
@@ -533,7 +534,7 @@ var tscPlugin = /* @__PURE__ */ __name((options, resolvedOptions) => ({
|
|
|
533
534
|
} else if ((0, import_node_fs2.existsSync)((0, import_config_tools2.joinPaths)(resolvedOptions.config.workspaceRoot, typeOutDir, `${entryPoint.replace(/^src\//, "")}.d.ts`))) {
|
|
534
535
|
dtsPath = (0, import_config_tools2.joinPaths)(resolvedOptions.config.workspaceRoot, typeOutDir, `${entryPoint.replace(/^src\//, "")}.d.ts`);
|
|
535
536
|
}
|
|
536
|
-
const ext = resolvedOptions.
|
|
537
|
+
const ext = resolvedOptions.format === "esm" ? "d.mts" : "d.ts";
|
|
537
538
|
if (process.env.WATCH !== "true" && process.env.DEV !== "true") {
|
|
538
539
|
bundleTypeDefinitions(dtsPath, bundlePath, resolvedOptions.external ?? [], resolvedOptions);
|
|
539
540
|
const dtsContents = await import_promises2.default.readFile(`${bundlePath}.d.ts`, "utf8");
|
|
@@ -555,9 +556,6 @@ function getTypeDependencyPackageName(npmPackage) {
|
|
|
555
556
|
__name(getTypeDependencyPackageName, "getTypeDependencyPackageName");
|
|
556
557
|
|
|
557
558
|
// src/config.ts
|
|
558
|
-
var getOutputExtensionMap = /* @__PURE__ */ __name((options, pkgType) => {
|
|
559
|
-
return options.outExtension ? options.outExtension(options.format, pkgType) : (0, import_get_out_extension.getOutExtension)(options.format, pkgType);
|
|
560
|
-
}, "getOutputExtensionMap");
|
|
561
559
|
var getDefaultBuildPlugins = /* @__PURE__ */ __name((options, resolvedOptions) => [
|
|
562
560
|
nodeProtocolPlugin(options, resolvedOptions),
|
|
563
561
|
resolvePathsPlugin(options, resolvedOptions),
|
|
@@ -806,9 +804,6 @@ var resolveOptions = /* @__PURE__ */ __name(async (userOptions) => {
|
|
|
806
804
|
if (!(0, import_node_fs3.existsSync)(packageJsonPath)) {
|
|
807
805
|
throw new Error("Cannot find package.json configuration");
|
|
808
806
|
}
|
|
809
|
-
const packageJsonFile = await import_promises3.default.readFile(packageJsonPath, "utf8");
|
|
810
|
-
const packageJson = JSON.parse(packageJsonFile);
|
|
811
|
-
const outExtension = getOutputExtensionMap(options, packageJson.type);
|
|
812
807
|
const env = (0, import_build_tools.getEnv)("esbuild", options);
|
|
813
808
|
const result = {
|
|
814
809
|
...options,
|
|
@@ -851,7 +846,6 @@ var resolveOptions = /* @__PURE__ */ __name(async (userOptions) => {
|
|
|
851
846
|
bundle: userOptions.bundle !== false,
|
|
852
847
|
keepNames: true,
|
|
853
848
|
watch: userOptions.watch === true,
|
|
854
|
-
outExtension,
|
|
855
849
|
footer: userOptions.footer,
|
|
856
850
|
banner: {
|
|
857
851
|
js: options.banner || import_build_tools.DEFAULT_COMPILED_BANNER,
|
package/dist/build.cjs
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
5
|
-
require('./chunk-
|
|
6
|
-
require('./chunk-
|
|
4
|
+
var _chunkH7G4L4A7cjs = require('./chunk-H7G4L4A7.cjs');
|
|
5
|
+
require('./chunk-DITM26C7.cjs');
|
|
6
|
+
require('./chunk-5F7O7BRG.cjs');
|
|
7
7
|
require('./chunk-S6M44SSZ.cjs');
|
|
8
8
|
require('./chunk-WRBUO7H6.cjs');
|
|
9
|
-
require('./chunk-
|
|
9
|
+
require('./chunk-I2FH4C27.cjs');
|
|
10
10
|
require('./chunk-SSEYS7LI.cjs');
|
|
11
|
-
require('./chunk-
|
|
12
|
-
require('./chunk-
|
|
13
|
-
require('./chunk-
|
|
11
|
+
require('./chunk-3ENEOIKE.cjs');
|
|
12
|
+
require('./chunk-DEO4HWIA.cjs');
|
|
13
|
+
require('./chunk-F665CCSS.cjs');
|
|
14
14
|
require('./chunk-XITTOHOG.cjs');
|
|
15
15
|
require('./chunk-CGFDQ5AJ.cjs');
|
|
16
16
|
require('./chunk-EZGTDCYM.cjs');
|
|
@@ -18,4 +18,4 @@ require('./chunk-BGYQAVKQ.cjs');
|
|
|
18
18
|
|
|
19
19
|
|
|
20
20
|
|
|
21
|
-
exports.build =
|
|
21
|
+
exports.build = _chunkH7G4L4A7cjs.build; exports.cleanOutputPath = _chunkH7G4L4A7cjs.cleanOutputPath;
|
package/dist/build.js
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import {
|
|
2
2
|
build,
|
|
3
3
|
cleanOutputPath
|
|
4
|
-
} from "./chunk-
|
|
5
|
-
import "./chunk-
|
|
6
|
-
import "./chunk-
|
|
4
|
+
} from "./chunk-KFFQSANO.js";
|
|
5
|
+
import "./chunk-TUAAYWUJ.js";
|
|
6
|
+
import "./chunk-VZIK4SOK.js";
|
|
7
7
|
import "./chunk-T5272PC2.js";
|
|
8
8
|
import "./chunk-LYDEMC26.js";
|
|
9
|
-
import "./chunk-
|
|
9
|
+
import "./chunk-YWKYHSIN.js";
|
|
10
10
|
import "./chunk-Q3LOGZKI.js";
|
|
11
|
-
import "./chunk-
|
|
12
|
-
import "./chunk-
|
|
13
|
-
import "./chunk-
|
|
11
|
+
import "./chunk-LUJTYV5C.js";
|
|
12
|
+
import "./chunk-NCMOSDGN.js";
|
|
13
|
+
import "./chunk-4ATDIKBQ.js";
|
|
14
14
|
import "./chunk-YMTDVMD6.js";
|
|
15
15
|
import "./chunk-YNQ45EAM.js";
|
|
16
16
|
import "./chunk-GWG4HOQ6.js";
|
|
@@ -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 _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
|
|
3
|
+
var _chunkF665CCSScjs = require('./chunk-F665CCSS.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
var _chunkXITTOHOGcjs = require('./chunk-XITTOHOG.cjs');
|
|
@@ -65,6 +65,7 @@ function bundleTypeDefinitions(filename, outfile, externals, options) {
|
|
|
65
65
|
overrideTsconfig: {
|
|
66
66
|
compilerOptions: {
|
|
67
67
|
paths: {}
|
|
68
|
+
// bug with api extract + paths
|
|
68
69
|
}
|
|
69
70
|
}
|
|
70
71
|
},
|
|
@@ -84,7 +85,7 @@ function bundleTypeDefinitions(filename, outfile, externals, options) {
|
|
|
84
85
|
localBuild: true
|
|
85
86
|
});
|
|
86
87
|
if (extractorResult.succeeded === false) {
|
|
87
|
-
|
|
88
|
+
_chunkF665CCSScjs.writeError.call(void 0, `API Extractor completed with ${extractorResult.errorCount} ${extractorResult.errorCount === 1 ? "error" : "errors"}`);
|
|
88
89
|
throw new Error("API Extractor completed with errors");
|
|
89
90
|
}
|
|
90
91
|
}
|
|
@@ -110,7 +111,7 @@ var tscPlugin = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, (options,
|
|
|
110
111
|
} else if (_fs.existsSync.call(void 0, _chunkXITTOHOGcjs.joinPaths.call(void 0, resolvedOptions.config.workspaceRoot, typeOutDir, `${entryPoint.replace(/^src\//, "")}.d.ts`))) {
|
|
111
112
|
dtsPath = _chunkXITTOHOGcjs.joinPaths.call(void 0, resolvedOptions.config.workspaceRoot, typeOutDir, `${entryPoint.replace(/^src\//, "")}.d.ts`);
|
|
112
113
|
}
|
|
113
|
-
const ext = resolvedOptions.
|
|
114
|
+
const ext = resolvedOptions.format === "esm" ? "d.mts" : "d.ts";
|
|
114
115
|
if (process.env.WATCH !== "true" && process.env.DEV !== "true") {
|
|
115
116
|
bundleTypeDefinitions(dtsPath, bundlePath, _nullishCoalesce(resolvedOptions.external, () => ( [])), resolvedOptions);
|
|
116
117
|
const dtsContents = await _promises2.default.readFile(`${bundlePath}.d.ts`, "utf8");
|
|
@@ -177,7 +177,7 @@ var ColorConfigMapSchema = z.union([
|
|
|
177
177
|
var ExtendsItemSchema = z.string().trim().describe("The path to a base config file to use as a configuration preset file. Documentation can be found at https://github.com/unjs/c12#extending-configuration.");
|
|
178
178
|
var ExtendsSchema = ExtendsItemSchema.or(z.array(ExtendsItemSchema)).describe("The path to a base config file to use as a configuration preset file. Documentation can be found at https://github.com/unjs/c12#extending-configuration.");
|
|
179
179
|
var WorkspaceBotConfigSchema = z.object({
|
|
180
|
-
name: z.string().trim().default("
|
|
180
|
+
name: z.string().trim().default("stormie-bot").describe("The workspace bot user's name (this is the bot that will be used to perform various tasks)"),
|
|
181
181
|
email: z.string().trim().email().default("bot@stormsoftware.com").describe("The email of the workspace bot")
|
|
182
182
|
}).describe("The workspace's bot user's config used to automated various operations tasks");
|
|
183
183
|
var WorkspaceDirectoryConfigSchema = z.object({
|
|
@@ -6,13 +6,13 @@ var _chunkS6M44SSZcjs = require('./chunk-S6M44SSZ.cjs');
|
|
|
6
6
|
var _chunkWRBUO7H6cjs = require('./chunk-WRBUO7H6.cjs');
|
|
7
7
|
|
|
8
8
|
|
|
9
|
-
var
|
|
9
|
+
var _chunkI2FH4C27cjs = require('./chunk-I2FH4C27.cjs');
|
|
10
10
|
|
|
11
11
|
|
|
12
12
|
var _chunkSSEYS7LIcjs = require('./chunk-SSEYS7LI.cjs');
|
|
13
13
|
|
|
14
14
|
|
|
15
|
-
var
|
|
15
|
+
var _chunk3ENEOIKEcjs = require('./chunk-3ENEOIKE.cjs');
|
|
16
16
|
|
|
17
17
|
|
|
18
18
|
|
|
@@ -28,7 +28,7 @@ var _chunkA7M6QDWGcjs = require('./chunk-A7M6QDWG.cjs');
|
|
|
28
28
|
|
|
29
29
|
|
|
30
30
|
|
|
31
|
-
var
|
|
31
|
+
var _chunkF665CCSScjs = require('./chunk-F665CCSS.cjs');
|
|
32
32
|
|
|
33
33
|
|
|
34
34
|
|
|
@@ -97,7 +97,7 @@ var copyAssets = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, async (co
|
|
|
97
97
|
output: "src/"
|
|
98
98
|
});
|
|
99
99
|
}
|
|
100
|
-
|
|
100
|
+
_chunkF665CCSScjs.writeTrace.call(void 0, `\u{1F4DD} Copying the following assets to the output directory:
|
|
101
101
|
${pendingAssets.map((pendingAsset) => typeof pendingAsset === "string" ? ` - ${pendingAsset} -> ${outputPath}` : ` - ${pendingAsset.input}/${pendingAsset.glob} -> ${_chunkXITTOHOGcjs.joinPaths.call(void 0, outputPath, pendingAsset.output)}`).join("\n")}`, config);
|
|
102
102
|
const assetHandler = new (0, _copyassetshandler.CopyAssetsHandler)({
|
|
103
103
|
projectDir: projectRoot,
|
|
@@ -107,7 +107,7 @@ ${pendingAssets.map((pendingAsset) => typeof pendingAsset === "string" ? ` - ${p
|
|
|
107
107
|
});
|
|
108
108
|
await assetHandler.processAllAssetsOnce();
|
|
109
109
|
if (includeSrc === true) {
|
|
110
|
-
|
|
110
|
+
_chunkF665CCSScjs.writeDebug.call(void 0, `\u{1F4DD} Adding banner and writing source files: ${_chunkXITTOHOGcjs.joinPaths.call(void 0, outputPath, "src")}`, config);
|
|
111
111
|
const files = await _glob.glob.call(void 0, [
|
|
112
112
|
_chunkXITTOHOGcjs.joinPaths.call(void 0, config.workspaceRoot, outputPath, "src/**/*.ts"),
|
|
113
113
|
_chunkXITTOHOGcjs.joinPaths.call(void 0, config.workspaceRoot, outputPath, "src/**/*.tsx"),
|
|
@@ -146,7 +146,7 @@ var addPackageDependencies = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void
|
|
|
146
146
|
}
|
|
147
147
|
}
|
|
148
148
|
if (localPackages.length > 0) {
|
|
149
|
-
|
|
149
|
+
_chunkF665CCSScjs.writeTrace.call(void 0, `\u{1F4E6} Adding local packages to package.json: ${localPackages.map((p) => p.name).join(", ")}`);
|
|
150
150
|
const projectJsonFile = await _promises.readFile.call(void 0, _chunkXITTOHOGcjs.joinPaths.call(void 0, projectRoot, "project.json"), "utf8");
|
|
151
151
|
const projectJson = JSON.parse(projectJsonFile);
|
|
152
152
|
const projectName2 = projectJson.name;
|
|
@@ -180,12 +180,12 @@ var addPackageDependencies = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void
|
|
|
180
180
|
return ret;
|
|
181
181
|
}, _nullishCoalesce(packageJson.devDependencies, () => ( {})));
|
|
182
182
|
} else {
|
|
183
|
-
|
|
183
|
+
_chunkF665CCSScjs.writeTrace.call(void 0, "\u{1F4E6} No local packages dependencies to add to package.json");
|
|
184
184
|
}
|
|
185
185
|
return packageJson;
|
|
186
186
|
}, "addPackageDependencies");
|
|
187
187
|
var addWorkspacePackageJsonFields = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, async (config, projectRoot, sourceRoot, projectName, includeSrc = false, packageJson) => {
|
|
188
|
-
const workspaceRoot = config.workspaceRoot ? config.workspaceRoot :
|
|
188
|
+
const workspaceRoot = config.workspaceRoot ? config.workspaceRoot : _chunkF665CCSScjs.findWorkspaceRoot.call(void 0, );
|
|
189
189
|
const workspacePackageJsonContent = await _promises.readFile.call(void 0, _chunkXITTOHOGcjs.joinPaths.call(void 0, workspaceRoot, "package.json"), "utf8");
|
|
190
190
|
const workspacePackageJson = JSON.parse(workspacePackageJsonContent);
|
|
191
191
|
packageJson.type ??= "module";
|
|
@@ -254,7 +254,7 @@ var addPackageJsonExport = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0,
|
|
|
254
254
|
var _c12 = require('c12');
|
|
255
255
|
var _defu = require('defu'); var _defu2 = _interopRequireDefault(_defu);
|
|
256
256
|
var getConfigFileByName = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, async (fileName, filePath, options = {}) => {
|
|
257
|
-
const workspacePath = filePath ||
|
|
257
|
+
const workspacePath = filePath || _chunkF665CCSScjs.findWorkspaceRoot.call(void 0, filePath);
|
|
258
258
|
const configs = await Promise.all([
|
|
259
259
|
_c12.loadConfig.call(void 0, {
|
|
260
260
|
cwd: workspacePath,
|
|
@@ -283,12 +283,12 @@ var getConfigFileByName = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0,
|
|
|
283
283
|
return _defu2.default.call(void 0, _nullishCoalesce(configs[0], () => ( {})), _nullishCoalesce(configs[1], () => ( {})));
|
|
284
284
|
}, "getConfigFileByName");
|
|
285
285
|
var getConfigFile = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, async (filePath, additionalFileNames = []) => {
|
|
286
|
-
const workspacePath = filePath ? filePath :
|
|
286
|
+
const workspacePath = filePath ? filePath : _chunkF665CCSScjs.findWorkspaceRoot.call(void 0, filePath);
|
|
287
287
|
const result = await getConfigFileByName("storm-workspace", workspacePath);
|
|
288
288
|
let config = result.config;
|
|
289
289
|
const configFile = result.configFile;
|
|
290
290
|
if (config && configFile && Object.keys(config).length > 0 && !config.skipConfigLogging) {
|
|
291
|
-
|
|
291
|
+
_chunkF665CCSScjs.writeTrace.call(void 0, `Found Storm configuration file "${configFile.includes(`${workspacePath}/`) ? configFile.replace(`${workspacePath}/`, "") : configFile}" at "${workspacePath}"`, {
|
|
292
292
|
logLevel: "all"
|
|
293
293
|
});
|
|
294
294
|
}
|
|
@@ -297,7 +297,7 @@ var getConfigFile = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, async
|
|
|
297
297
|
for (const result2 of results) {
|
|
298
298
|
if (_optionalChain([result2, 'optionalAccess', _18 => _18.config]) && _optionalChain([result2, 'optionalAccess', _19 => _19.configFile]) && Object.keys(result2.config).length > 0) {
|
|
299
299
|
if (!config.skipConfigLogging && !result2.config.skipConfigLogging) {
|
|
300
|
-
|
|
300
|
+
_chunkF665CCSScjs.writeTrace.call(void 0, `Found alternative configuration file "${result2.configFile.includes(`${workspacePath}/`) ? result2.configFile.replace(`${workspacePath}/`, "") : result2.configFile}" at "${workspacePath}"`, {
|
|
301
301
|
logLevel: "all"
|
|
302
302
|
});
|
|
303
303
|
}
|
|
@@ -376,24 +376,24 @@ var getConfigEnv = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, () => {
|
|
|
376
376
|
cyclone: process.env[`${prefix}REGISTRY_CYCLONE`] || void 0,
|
|
377
377
|
container: process.env[`${prefix}REGISTRY_CONTAINER`] || void 0
|
|
378
378
|
},
|
|
379
|
-
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`])) ?
|
|
379
|
+
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`])) ? _chunkF665CCSScjs.getLogLevelLabel.call(void 0, Number.parseInt(process.env[`${prefix}LOG_LEVEL`])) : process.env[`${prefix}LOG_LEVEL`] : void 0,
|
|
380
380
|
skipConfigLogging: process.env[`${prefix}SKIP_CONFIG_LOGGING`] !== void 0 ? Boolean(process.env[`${prefix}SKIP_CONFIG_LOGGING`]) : void 0
|
|
381
381
|
};
|
|
382
|
-
const themeNames = Object.keys(process.env).filter((envKey) => envKey.startsWith(`${prefix}COLOR_`) &&
|
|
382
|
+
const themeNames = Object.keys(process.env).filter((envKey) => envKey.startsWith(`${prefix}COLOR_`) && _chunkF665CCSScjs.COLOR_KEYS.every((colorKey) => !envKey.startsWith(`${prefix}COLOR_LIGHT_${colorKey}`) && !envKey.startsWith(`${prefix}COLOR_DARK_${colorKey}`)));
|
|
383
383
|
config.colors = themeNames.length > 0 ? themeNames.reduce((ret, themeName) => {
|
|
384
384
|
ret[themeName] = getThemeColorConfigEnv(prefix, themeName);
|
|
385
385
|
return ret;
|
|
386
386
|
}, {}) : getThemeColorConfigEnv(prefix);
|
|
387
|
-
if (config.docs ===
|
|
388
|
-
if (config.homepage ===
|
|
389
|
-
config.docs = `${
|
|
387
|
+
if (config.docs === _chunkF665CCSScjs.STORM_DEFAULT_DOCS) {
|
|
388
|
+
if (config.homepage === _chunkF665CCSScjs.STORM_DEFAULT_HOMEPAGE) {
|
|
389
|
+
config.docs = `${_chunkF665CCSScjs.STORM_DEFAULT_HOMEPAGE}/projects/${config.name}/docs`;
|
|
390
390
|
} else {
|
|
391
391
|
config.docs = `${config.homepage}/docs`;
|
|
392
392
|
}
|
|
393
393
|
}
|
|
394
|
-
if (config.licensing ===
|
|
395
|
-
if (config.homepage ===
|
|
396
|
-
config.licensing = `${
|
|
394
|
+
if (config.licensing === _chunkF665CCSScjs.STORM_DEFAULT_LICENSING) {
|
|
395
|
+
if (config.homepage === _chunkF665CCSScjs.STORM_DEFAULT_HOMEPAGE) {
|
|
396
|
+
config.licensing = `${_chunkF665CCSScjs.STORM_DEFAULT_HOMEPAGE}/projects/${config.name}/licensing`;
|
|
397
397
|
} else {
|
|
398
398
|
config.licensing = `${config.homepage}/docs`;
|
|
399
399
|
}
|
|
@@ -609,8 +609,8 @@ var setConfigEnv = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, (config
|
|
|
609
609
|
if (config.logLevel) {
|
|
610
610
|
process.env[`${prefix}LOG_LEVEL`] = String(config.logLevel);
|
|
611
611
|
process.env.LOG_LEVEL = String(config.logLevel);
|
|
612
|
-
process.env.NX_VERBOSE_LOGGING = String(
|
|
613
|
-
process.env.RUST_BACKTRACE =
|
|
612
|
+
process.env.NX_VERBOSE_LOGGING = String(_chunkF665CCSScjs.getLogLevel.call(void 0, config.logLevel) >= _chunkF665CCSScjs.LogLevel.DEBUG ? true : false);
|
|
613
|
+
process.env.RUST_BACKTRACE = _chunkF665CCSScjs.getLogLevel.call(void 0, config.logLevel) >= _chunkF665CCSScjs.LogLevel.DEBUG ? "full" : "none";
|
|
614
614
|
}
|
|
615
615
|
if (config.skipConfigLogging !== void 0) {
|
|
616
616
|
process.env[`${prefix}SKIP_CONFIG_LOGGING`] = String(config.skipConfigLogging);
|
|
@@ -726,17 +726,17 @@ var createStormConfig = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, as
|
|
|
726
726
|
if (!_optionalChain([_static_cache, 'optionalAccess', _42 => _42.data]) || !_optionalChain([_static_cache, 'optionalAccess', _43 => _43.timestamp]) || _static_cache.timestamp < Date.now() - 8e3) {
|
|
727
727
|
let _workspaceRoot = workspaceRoot;
|
|
728
728
|
if (!_workspaceRoot) {
|
|
729
|
-
_workspaceRoot =
|
|
729
|
+
_workspaceRoot = _chunkF665CCSScjs.findWorkspaceRoot.call(void 0, );
|
|
730
730
|
}
|
|
731
731
|
const configEnv = getConfigEnv();
|
|
732
|
-
const defaultConfig = await
|
|
732
|
+
const defaultConfig = await _chunkF665CCSScjs.getDefaultConfig.call(void 0, _workspaceRoot);
|
|
733
733
|
const configFile = await getConfigFile(_workspaceRoot);
|
|
734
734
|
if (!configFile && !skipLogs) {
|
|
735
|
-
|
|
735
|
+
_chunkF665CCSScjs.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", {
|
|
736
736
|
logLevel: "all"
|
|
737
737
|
});
|
|
738
738
|
}
|
|
739
|
-
result = await
|
|
739
|
+
result = await _chunkF665CCSScjs.StormConfigSchema.parseAsync(_defu2.default.call(void 0, configEnv, configFile, defaultConfig));
|
|
740
740
|
result.workspaceRoot ??= _workspaceRoot;
|
|
741
741
|
} else {
|
|
742
742
|
result = _static_cache.data;
|
|
@@ -771,8 +771,8 @@ var loadStormConfig = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, asyn
|
|
|
771
771
|
const config = await createStormConfig(void 0, void 0, workspaceRoot, skipLogs);
|
|
772
772
|
setConfigEnv(config);
|
|
773
773
|
if (!skipLogs && !config.skipConfigLogging) {
|
|
774
|
-
|
|
775
|
-
${
|
|
774
|
+
_chunkF665CCSScjs.writeTrace.call(void 0, `\u2699\uFE0F Using Storm Workspace configuration:
|
|
775
|
+
${_chunkF665CCSScjs.formatLogMessage.call(void 0, config)}`, config);
|
|
776
776
|
}
|
|
777
777
|
return config;
|
|
778
778
|
}, "loadStormConfig");
|
|
@@ -785,7 +785,7 @@ var getConfig = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, (workspace
|
|
|
785
785
|
// ../build-tools/src/utilities/get-entry-points.ts
|
|
786
786
|
|
|
787
787
|
var getEntryPoints = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, async (config, projectRoot, sourceRoot, entry, emitOnAll = false) => {
|
|
788
|
-
const workspaceRoot = config.workspaceRoot ? config.workspaceRoot :
|
|
788
|
+
const workspaceRoot = config.workspaceRoot ? config.workspaceRoot : _chunkF665CCSScjs.findWorkspaceRoot.call(void 0, );
|
|
789
789
|
const entryPoints = [];
|
|
790
790
|
if (entry) {
|
|
791
791
|
if (Array.isArray(entry)) {
|
|
@@ -808,7 +808,7 @@ var getEntryPoints = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, async
|
|
|
808
808
|
results.push(...files.reduce((ret, filePath) => {
|
|
809
809
|
const result = _chunkXITTOHOGcjs.correctPaths.call(void 0, _chunkXITTOHOGcjs.joinPaths.call(void 0, filePath.path, filePath.name).replaceAll(_chunkXITTOHOGcjs.correctPaths.call(void 0, workspaceRoot), "").replaceAll(_chunkXITTOHOGcjs.correctPaths.call(void 0, projectRoot), ""));
|
|
810
810
|
if (result) {
|
|
811
|
-
|
|
811
|
+
_chunkF665CCSScjs.writeDebug.call(void 0, `Trying to add entry point ${result} at "${_chunkXITTOHOGcjs.joinPaths.call(void 0, filePath.path, filePath.name)}"`, config);
|
|
812
812
|
if (!results.includes(result)) {
|
|
813
813
|
results.push(result);
|
|
814
814
|
}
|
|
@@ -836,28 +836,6 @@ var getEnv = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, (builder, opt
|
|
|
836
836
|
};
|
|
837
837
|
}, "getEnv");
|
|
838
838
|
|
|
839
|
-
// ../build-tools/src/utilities/get-out-extension.ts
|
|
840
|
-
function getOutExtension(format, pkgType) {
|
|
841
|
-
let jsExtension = ".js";
|
|
842
|
-
let dtsExtension = ".d.ts";
|
|
843
|
-
if (pkgType === "module" && format === "cjs") {
|
|
844
|
-
jsExtension = ".cjs";
|
|
845
|
-
dtsExtension = ".d.cts";
|
|
846
|
-
}
|
|
847
|
-
if (pkgType !== "module" && format === "esm") {
|
|
848
|
-
jsExtension = ".mjs";
|
|
849
|
-
dtsExtension = ".d.mts";
|
|
850
|
-
}
|
|
851
|
-
if (format === "iife") {
|
|
852
|
-
jsExtension = ".global.js";
|
|
853
|
-
}
|
|
854
|
-
return {
|
|
855
|
-
js: jsExtension,
|
|
856
|
-
dts: dtsExtension
|
|
857
|
-
};
|
|
858
|
-
}
|
|
859
|
-
_chunkBGYQAVKQcjs.__name.call(void 0, getOutExtension, "getOutExtension");
|
|
860
|
-
|
|
861
839
|
// ../build-tools/src/utilities/read-nx-config.ts
|
|
862
840
|
|
|
863
841
|
|
|
@@ -866,17 +844,14 @@ _chunkBGYQAVKQcjs.__name.call(void 0, getOutExtension, "getOutExtension");
|
|
|
866
844
|
var _createtaskgraph = require('nx/src/tasks-runner/create-task-graph');
|
|
867
845
|
|
|
868
846
|
// src/config.ts
|
|
869
|
-
var getOutputExtensionMap = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, (options, pkgType) => {
|
|
870
|
-
return options.outExtension ? options.outExtension(options.format, pkgType) : getOutExtension(options.format, pkgType);
|
|
871
|
-
}, "getOutputExtensionMap");
|
|
872
847
|
var getDefaultBuildPlugins = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, (options, resolvedOptions) => [
|
|
873
848
|
_chunkWRBUO7H6cjs.nodeProtocolPlugin.call(void 0, options, resolvedOptions),
|
|
874
849
|
_chunkSSEYS7LIcjs.resolvePathsPlugin.call(void 0, options, resolvedOptions),
|
|
875
850
|
_chunkEZGTDCYMcjs.fixImportsPlugin.call(void 0, options, resolvedOptions),
|
|
876
851
|
_chunkS6M44SSZcjs.nativeNodeModulesPlugin.call(void 0, options, resolvedOptions),
|
|
877
852
|
_chunkCGFDQ5AJcjs.esmSplitCodeToCjsPlugin.call(void 0, options, resolvedOptions),
|
|
878
|
-
|
|
879
|
-
|
|
853
|
+
_chunk3ENEOIKEcjs.tscPlugin.call(void 0, options, resolvedOptions),
|
|
854
|
+
_chunkI2FH4C27cjs.onErrorPlugin.call(void 0, options, resolvedOptions)
|
|
880
855
|
], "getDefaultBuildPlugins");
|
|
881
856
|
var DEFAULT_BUILD_OPTIONS = {
|
|
882
857
|
platform: "node",
|
|
@@ -930,5 +905,4 @@ var DEFAULT_BUILD_OPTIONS = {
|
|
|
930
905
|
|
|
931
906
|
|
|
932
907
|
|
|
933
|
-
|
|
934
|
-
exports.DEFAULT_COMPILED_BANNER = DEFAULT_COMPILED_BANNER; exports.DEFAULT_TARGET = DEFAULT_TARGET; exports.copyAssets = copyAssets; exports.addPackageDependencies = addPackageDependencies; exports.addWorkspacePackageJsonFields = addWorkspacePackageJsonFields; exports.addPackageJsonExport = addPackageJsonExport; exports.getConfig = getConfig; exports.getEntryPoints = getEntryPoints; exports.getEnv = getEnv; exports.getOutputExtensionMap = getOutputExtensionMap; exports.getDefaultBuildPlugins = getDefaultBuildPlugins; exports.DEFAULT_BUILD_OPTIONS = DEFAULT_BUILD_OPTIONS;
|
|
908
|
+
exports.DEFAULT_COMPILED_BANNER = DEFAULT_COMPILED_BANNER; exports.DEFAULT_TARGET = DEFAULT_TARGET; exports.copyAssets = copyAssets; exports.addPackageDependencies = addPackageDependencies; exports.addWorkspacePackageJsonFields = addWorkspacePackageJsonFields; exports.addPackageJsonExport = addPackageJsonExport; exports.getConfig = getConfig; exports.getEntryPoints = getEntryPoints; exports.getEnv = getEnv; exports.getDefaultBuildPlugins = getDefaultBuildPlugins; exports.DEFAULT_BUILD_OPTIONS = DEFAULT_BUILD_OPTIONS;
|
|
@@ -1,7 +1,7 @@
|
|
|
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(); } }
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
4
|
+
var _chunkF665CCSScjs = require('./chunk-F665CCSS.cjs');
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
|
|
@@ -86,8 +86,8 @@ var depsCheckPlugin = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, (bun
|
|
|
86
86
|
const filteredMissingDeps = missingDependencies.filter((dep) => {
|
|
87
87
|
return !missingIgnore.some((pattern) => dep.match(pattern)) && !peerDependencies.includes(dep);
|
|
88
88
|
});
|
|
89
|
-
|
|
90
|
-
|
|
89
|
+
_chunkF665CCSScjs.writeWarning.call(void 0, `Unused Dependencies: ${JSON.stringify(filteredUnusedDeps)}`);
|
|
90
|
+
_chunkF665CCSScjs.writeError.call(void 0, `Missing Dependencies: ${JSON.stringify(filteredMissingDeps)}`);
|
|
91
91
|
if (filteredMissingDeps.length > 0) {
|
|
92
92
|
throw new Error(`Missing dependencies detected - please install them:
|
|
93
93
|
${JSON.stringify(filteredMissingDeps)}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
4
|
+
var _chunkF665CCSScjs = require('./chunk-F665CCSS.cjs');
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
var _chunkBGYQAVKQcjs = require('./chunk-BGYQAVKQ.cjs');
|
|
@@ -9,8 +9,8 @@ var _chunkBGYQAVKQcjs = require('./chunk-BGYQAVKQ.cjs');
|
|
|
9
9
|
// src/clean.ts
|
|
10
10
|
var _promises = require('fs/promises');
|
|
11
11
|
async function clean(name = "ESBuild", directory, config) {
|
|
12
|
-
|
|
13
|
-
const stopwatch =
|
|
12
|
+
_chunkF665CCSScjs.writeDebug.call(void 0, ` \u{1F9F9} Cleaning ${name} output path: ${directory}`, config);
|
|
13
|
+
const stopwatch = _chunkF665CCSScjs.getStopwatch.call(void 0, `${name} output clean`);
|
|
14
14
|
await cleanDirectories(name, directory, config);
|
|
15
15
|
stopwatch();
|
|
16
16
|
}
|
|
@@ -177,7 +177,7 @@ var ColorConfigMapSchema = _zod2.default.union([
|
|
|
177
177
|
var ExtendsItemSchema = _zod2.default.string().trim().describe("The path to a base config file to use as a configuration preset file. Documentation can be found at https://github.com/unjs/c12#extending-configuration.");
|
|
178
178
|
var ExtendsSchema = ExtendsItemSchema.or(_zod2.default.array(ExtendsItemSchema)).describe("The path to a base config file to use as a configuration preset file. Documentation can be found at https://github.com/unjs/c12#extending-configuration.");
|
|
179
179
|
var WorkspaceBotConfigSchema = _zod2.default.object({
|
|
180
|
-
name: _zod2.default.string().trim().default("
|
|
180
|
+
name: _zod2.default.string().trim().default("stormie-bot").describe("The workspace bot user's name (this is the bot that will be used to perform various tasks)"),
|
|
181
181
|
email: _zod2.default.string().trim().email().default("bot@stormsoftware.com").describe("The email of the workspace bot")
|
|
182
182
|
}).describe("The workspace's bot user's config used to automated various operations tasks");
|
|
183
183
|
var WorkspaceDirectoryConfigSchema = _zod2.default.object({
|