@storm-software/unbuild 0.39.16 → 0.40.0
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/bin/unbuild.cjs +14 -9
- package/bin/unbuild.js +14 -9
- package/dist/build.cjs +7 -7
- package/dist/build.js +6 -6
- package/dist/{chunk-NFAQF6SG.js → chunk-2PUJT7MC.js} +1 -1
- package/dist/{chunk-ICS2FLHB.js → chunk-3BDIPKMO.js} +1 -1
- package/dist/{chunk-7AESM4QF.cjs → chunk-3BXXHK3F.cjs} +2 -2
- package/dist/{chunk-M7TXTZYC.js → chunk-DUDE4LYM.js} +1 -1
- package/dist/{chunk-MNQGUEQ7.cjs → chunk-F4MPFQDI.cjs} +3 -3
- package/dist/{chunk-4IZTCCLU.js → chunk-HZNOKNKE.js} +1 -1
- package/dist/{chunk-3VWVLTGD.cjs → chunk-ITHOVA3D.cjs} +3 -3
- package/dist/{chunk-QOGZYBKK.js → chunk-J4UJGE35.js} +18 -13
- package/dist/{chunk-HEBZFJ2N.cjs → chunk-NVI74UAF.cjs} +2 -2
- package/dist/{chunk-OFV7JN7O.cjs → chunk-PWE7CANF.cjs} +1 -1
- package/dist/{chunk-GMQCUY6K.js → chunk-SMAV5VSP.js} +1 -1
- package/dist/{chunk-U5NQ3CH3.cjs → chunk-YIDTYRQY.cjs} +111 -106
- package/dist/clean.cjs +3 -3
- package/dist/clean.js +2 -2
- package/dist/index.cjs +7 -7
- package/dist/index.js +6 -6
- package/dist/plugins/analyze.cjs +3 -3
- package/dist/plugins/analyze.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/package.json +1 -1
package/bin/unbuild.cjs
CHANGED
|
@@ -185,7 +185,7 @@ var stormWorkspaceConfigSchema = import_zod.default.object({
|
|
|
185
185
|
"staging",
|
|
186
186
|
"production"
|
|
187
187
|
]).default("production").describe("The current runtime environment mode for the package"),
|
|
188
|
-
workspaceRoot: import_zod.default.string().trim().
|
|
188
|
+
workspaceRoot: import_zod.default.string().trim().describe("The root directory of the workspace"),
|
|
189
189
|
externalPackagePatterns: import_zod.default.array(import_zod.default.string()).default([]).describe("The build will use these package patterns to determine if they should be external to the bundle"),
|
|
190
190
|
skipCache: import_zod.default.boolean().default(false).describe("Should all known types of workspace caching be skipped?"),
|
|
191
191
|
directories: WorkspaceDirectoryConfigSchema,
|
|
@@ -860,7 +860,7 @@ var getConfigFile = /* @__PURE__ */ __name(async (filePath, additionalFileNames
|
|
|
860
860
|
}
|
|
861
861
|
}
|
|
862
862
|
}
|
|
863
|
-
if (!config) {
|
|
863
|
+
if (!config || Object.keys(config).length === 0) {
|
|
864
864
|
return void 0;
|
|
865
865
|
}
|
|
866
866
|
config.configFile = configFile;
|
|
@@ -1331,7 +1331,7 @@ var setBaseThemeColorConfigEnv = /* @__PURE__ */ __name((prefix, config) => {
|
|
|
1331
1331
|
// ../config-tools/src/create-storm-config.ts
|
|
1332
1332
|
var _extension_cache = /* @__PURE__ */ new WeakMap();
|
|
1333
1333
|
var _static_cache = void 0;
|
|
1334
|
-
var createStormWorkspaceConfig = /* @__PURE__ */ __name(async (extensionName, schema, workspaceRoot, skipLogs = false) => {
|
|
1334
|
+
var createStormWorkspaceConfig = /* @__PURE__ */ __name(async (extensionName, schema, workspaceRoot, skipLogs = false, useDefault = true) => {
|
|
1335
1335
|
let result;
|
|
1336
1336
|
if (!_static_cache?.data || !_static_cache?.timestamp || _static_cache.timestamp < Date.now() - 8e3) {
|
|
1337
1337
|
let _workspaceRoot = workspaceRoot;
|
|
@@ -1339,13 +1339,18 @@ var createStormWorkspaceConfig = /* @__PURE__ */ __name(async (extensionName, sc
|
|
|
1339
1339
|
_workspaceRoot = findWorkspaceRoot();
|
|
1340
1340
|
}
|
|
1341
1341
|
const configEnv = getConfigEnv();
|
|
1342
|
-
const defaultConfig = await getDefaultConfig(_workspaceRoot);
|
|
1343
1342
|
const configFile = await getConfigFile(_workspaceRoot);
|
|
1344
|
-
if (!configFile
|
|
1345
|
-
|
|
1346
|
-
|
|
1347
|
-
|
|
1343
|
+
if (!configFile) {
|
|
1344
|
+
if (!skipLogs) {
|
|
1345
|
+
writeWarning("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", {
|
|
1346
|
+
logLevel: "all"
|
|
1347
|
+
});
|
|
1348
|
+
}
|
|
1349
|
+
if (useDefault === false) {
|
|
1350
|
+
return void 0;
|
|
1351
|
+
}
|
|
1348
1352
|
}
|
|
1353
|
+
const defaultConfig = await getDefaultConfig(_workspaceRoot);
|
|
1349
1354
|
result = await stormWorkspaceConfigSchema.parseAsync((0, import_defu2.default)(configEnv, configFile, defaultConfig));
|
|
1350
1355
|
result.workspaceRoot ??= _workspaceRoot;
|
|
1351
1356
|
} else {
|
|
@@ -1378,7 +1383,7 @@ var createConfigExtension = /* @__PURE__ */ __name((extensionName, schema) => {
|
|
|
1378
1383
|
return extension;
|
|
1379
1384
|
}, "createConfigExtension");
|
|
1380
1385
|
var loadStormWorkspaceConfig = /* @__PURE__ */ __name(async (workspaceRoot, skipLogs = false) => {
|
|
1381
|
-
const config = await createStormWorkspaceConfig(void 0, void 0, workspaceRoot, skipLogs);
|
|
1386
|
+
const config = await createStormWorkspaceConfig(void 0, void 0, workspaceRoot, skipLogs, true);
|
|
1382
1387
|
setConfigEnv(config);
|
|
1383
1388
|
if (!skipLogs && !config.skipConfigLogging) {
|
|
1384
1389
|
writeTrace(`\u2699\uFE0F Using Storm Workspace configuration:
|
package/bin/unbuild.js
CHANGED
|
@@ -164,7 +164,7 @@ var stormWorkspaceConfigSchema = z.object({
|
|
|
164
164
|
"staging",
|
|
165
165
|
"production"
|
|
166
166
|
]).default("production").describe("The current runtime environment mode for the package"),
|
|
167
|
-
workspaceRoot: z.string().trim().
|
|
167
|
+
workspaceRoot: z.string().trim().describe("The root directory of the workspace"),
|
|
168
168
|
externalPackagePatterns: z.array(z.string()).default([]).describe("The build will use these package patterns to determine if they should be external to the bundle"),
|
|
169
169
|
skipCache: z.boolean().default(false).describe("Should all known types of workspace caching be skipped?"),
|
|
170
170
|
directories: WorkspaceDirectoryConfigSchema,
|
|
@@ -839,7 +839,7 @@ var getConfigFile = /* @__PURE__ */ __name(async (filePath, additionalFileNames
|
|
|
839
839
|
}
|
|
840
840
|
}
|
|
841
841
|
}
|
|
842
|
-
if (!config) {
|
|
842
|
+
if (!config || Object.keys(config).length === 0) {
|
|
843
843
|
return void 0;
|
|
844
844
|
}
|
|
845
845
|
config.configFile = configFile;
|
|
@@ -1310,7 +1310,7 @@ var setBaseThemeColorConfigEnv = /* @__PURE__ */ __name((prefix, config) => {
|
|
|
1310
1310
|
// ../config-tools/src/create-storm-config.ts
|
|
1311
1311
|
var _extension_cache = /* @__PURE__ */ new WeakMap();
|
|
1312
1312
|
var _static_cache = void 0;
|
|
1313
|
-
var createStormWorkspaceConfig = /* @__PURE__ */ __name(async (extensionName, schema, workspaceRoot, skipLogs = false) => {
|
|
1313
|
+
var createStormWorkspaceConfig = /* @__PURE__ */ __name(async (extensionName, schema, workspaceRoot, skipLogs = false, useDefault = true) => {
|
|
1314
1314
|
let result;
|
|
1315
1315
|
if (!_static_cache?.data || !_static_cache?.timestamp || _static_cache.timestamp < Date.now() - 8e3) {
|
|
1316
1316
|
let _workspaceRoot = workspaceRoot;
|
|
@@ -1318,13 +1318,18 @@ var createStormWorkspaceConfig = /* @__PURE__ */ __name(async (extensionName, sc
|
|
|
1318
1318
|
_workspaceRoot = findWorkspaceRoot();
|
|
1319
1319
|
}
|
|
1320
1320
|
const configEnv = getConfigEnv();
|
|
1321
|
-
const defaultConfig = await getDefaultConfig(_workspaceRoot);
|
|
1322
1321
|
const configFile = await getConfigFile(_workspaceRoot);
|
|
1323
|
-
if (!configFile
|
|
1324
|
-
|
|
1325
|
-
|
|
1326
|
-
|
|
1322
|
+
if (!configFile) {
|
|
1323
|
+
if (!skipLogs) {
|
|
1324
|
+
writeWarning("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", {
|
|
1325
|
+
logLevel: "all"
|
|
1326
|
+
});
|
|
1327
|
+
}
|
|
1328
|
+
if (useDefault === false) {
|
|
1329
|
+
return void 0;
|
|
1330
|
+
}
|
|
1327
1331
|
}
|
|
1332
|
+
const defaultConfig = await getDefaultConfig(_workspaceRoot);
|
|
1328
1333
|
result = await stormWorkspaceConfigSchema.parseAsync(defu2(configEnv, configFile, defaultConfig));
|
|
1329
1334
|
result.workspaceRoot ??= _workspaceRoot;
|
|
1330
1335
|
} else {
|
|
@@ -1357,7 +1362,7 @@ var createConfigExtension = /* @__PURE__ */ __name((extensionName, schema) => {
|
|
|
1357
1362
|
return extension;
|
|
1358
1363
|
}, "createConfigExtension");
|
|
1359
1364
|
var loadStormWorkspaceConfig = /* @__PURE__ */ __name(async (workspaceRoot, skipLogs = false) => {
|
|
1360
|
-
const config = await createStormWorkspaceConfig(void 0, void 0, workspaceRoot, skipLogs);
|
|
1365
|
+
const config = await createStormWorkspaceConfig(void 0, void 0, workspaceRoot, skipLogs, true);
|
|
1361
1366
|
setConfigEnv(config);
|
|
1362
1367
|
if (!skipLogs && !config.skipConfigLogging) {
|
|
1363
1368
|
writeTrace(`\u2699\uFE0F Using Storm Workspace configuration:
|
package/dist/build.cjs
CHANGED
|
@@ -5,12 +5,12 @@
|
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
|
|
8
|
-
var
|
|
9
|
-
require('./chunk-
|
|
10
|
-
require('./chunk-
|
|
11
|
-
require('./chunk-
|
|
12
|
-
require('./chunk-
|
|
13
|
-
require('./chunk-
|
|
8
|
+
var _chunkYIDTYRQYcjs = require('./chunk-YIDTYRQY.cjs');
|
|
9
|
+
require('./chunk-ITHOVA3D.cjs');
|
|
10
|
+
require('./chunk-3BXXHK3F.cjs');
|
|
11
|
+
require('./chunk-F4MPFQDI.cjs');
|
|
12
|
+
require('./chunk-NVI74UAF.cjs');
|
|
13
|
+
require('./chunk-PWE7CANF.cjs');
|
|
14
14
|
require('./chunk-BGYQAVKQ.cjs');
|
|
15
15
|
|
|
16
16
|
|
|
@@ -19,4 +19,4 @@ require('./chunk-BGYQAVKQ.cjs');
|
|
|
19
19
|
|
|
20
20
|
|
|
21
21
|
|
|
22
|
-
exports.build =
|
|
22
|
+
exports.build = _chunkYIDTYRQYcjs.build; exports.cleanOutputPath = _chunkYIDTYRQYcjs.cleanOutputPath; exports.copyBuildAssets = _chunkYIDTYRQYcjs.copyBuildAssets; exports.executeUnbuild = _chunkYIDTYRQYcjs.executeUnbuild; exports.generatePackageJson = _chunkYIDTYRQYcjs.generatePackageJson; exports.resolveOptions = _chunkYIDTYRQYcjs.resolveOptions;
|
package/dist/build.js
CHANGED
|
@@ -5,12 +5,12 @@ import {
|
|
|
5
5
|
executeUnbuild,
|
|
6
6
|
generatePackageJson,
|
|
7
7
|
resolveOptions
|
|
8
|
-
} from "./chunk-
|
|
9
|
-
import "./chunk-
|
|
10
|
-
import "./chunk-
|
|
11
|
-
import "./chunk-
|
|
12
|
-
import "./chunk-
|
|
13
|
-
import "./chunk-
|
|
8
|
+
} from "./chunk-J4UJGE35.js";
|
|
9
|
+
import "./chunk-DUDE4LYM.js";
|
|
10
|
+
import "./chunk-SMAV5VSP.js";
|
|
11
|
+
import "./chunk-HZNOKNKE.js";
|
|
12
|
+
import "./chunk-2PUJT7MC.js";
|
|
13
|
+
import "./chunk-3BDIPKMO.js";
|
|
14
14
|
import "./chunk-3GQAWCBQ.js";
|
|
15
15
|
export {
|
|
16
16
|
build,
|
|
@@ -368,7 +368,7 @@ var stormWorkspaceConfigSchema = z.object({
|
|
|
368
368
|
"staging",
|
|
369
369
|
"production"
|
|
370
370
|
]).default("production").describe("The current runtime environment mode for the package"),
|
|
371
|
-
workspaceRoot: z.string().trim().
|
|
371
|
+
workspaceRoot: z.string().trim().describe("The root directory of the workspace"),
|
|
372
372
|
externalPackagePatterns: z.array(z.string()).default([]).describe("The build will use these package patterns to determine if they should be external to the bundle"),
|
|
373
373
|
skipCache: z.boolean().default(false).describe("Should all known types of workspace caching be skipped?"),
|
|
374
374
|
directories: WorkspaceDirectoryConfigSchema,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _chunkPWE7CANFcjs = require('./chunk-PWE7CANF.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
var _chunkBGYQAVKQcjs = require('./chunk-BGYQAVKQ.cjs');
|
|
@@ -25,7 +25,7 @@ var analyzePlugin = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, (optio
|
|
|
25
25
|
renderChunk(source, chunk) {
|
|
26
26
|
const sourceBytes = formatBytes(source.length);
|
|
27
27
|
const fileName = chunk.fileName;
|
|
28
|
-
|
|
28
|
+
_chunkPWE7CANFcjs.writeInfo.call(void 0, ` - ${fileName} ${sourceBytes}`, options.config);
|
|
29
29
|
}
|
|
30
30
|
};
|
|
31
31
|
}, "analyzePlugin");
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _chunkPWE7CANFcjs = require('./chunk-PWE7CANF.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
var _chunkBGYQAVKQcjs = require('./chunk-BGYQAVKQ.cjs');
|
|
@@ -10,7 +10,7 @@ var onErrorPlugin = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, (optio
|
|
|
10
10
|
name: "storm:on-error",
|
|
11
11
|
buildEnd(error) {
|
|
12
12
|
if (error) {
|
|
13
|
-
|
|
13
|
+
_chunkPWE7CANFcjs.writeError.call(void 0, `The following errors occurred during the build:
|
|
14
14
|
${error ? error.message : "Unknown build error"}
|
|
15
15
|
|
|
16
16
|
`, options.config);
|
|
@@ -18,7 +18,7 @@ ${error ? error.message : "Unknown build error"}
|
|
|
18
18
|
}
|
|
19
19
|
},
|
|
20
20
|
renderError(error) {
|
|
21
|
-
|
|
21
|
+
_chunkPWE7CANFcjs.writeError.call(void 0, `The following errors occurred during the build:
|
|
22
22
|
${error ? error.message : "Unknown build error"}
|
|
23
23
|
|
|
24
24
|
`, options.config);
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
4
|
+
var _chunkPWE7CANFcjs = require('./chunk-PWE7CANF.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 = "Unbuild", directory, config) {
|
|
12
|
-
|
|
13
|
-
const stopwatch =
|
|
12
|
+
_chunkPWE7CANFcjs.writeDebug.call(void 0, ` \u{1F9F9} Cleaning ${name} output path: ${directory}`, config);
|
|
13
|
+
const stopwatch = _chunkPWE7CANFcjs.getStopwatch.call(void 0, `${name} output clean`);
|
|
14
14
|
await cleanDirectories(name, directory, config);
|
|
15
15
|
stopwatch();
|
|
16
16
|
}
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import {
|
|
2
2
|
cleanDirectories
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-DUDE4LYM.js";
|
|
4
4
|
import {
|
|
5
5
|
analyzePlugin
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-SMAV5VSP.js";
|
|
7
7
|
import {
|
|
8
8
|
onErrorPlugin
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-HZNOKNKE.js";
|
|
10
10
|
import {
|
|
11
11
|
loadConfig,
|
|
12
12
|
tscPlugin
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-2PUJT7MC.js";
|
|
14
14
|
import {
|
|
15
15
|
COLOR_KEYS,
|
|
16
16
|
LogLevel,
|
|
@@ -33,7 +33,7 @@ import {
|
|
|
33
33
|
writeSuccess,
|
|
34
34
|
writeTrace,
|
|
35
35
|
writeWarning
|
|
36
|
-
} from "./chunk-
|
|
36
|
+
} from "./chunk-3BDIPKMO.js";
|
|
37
37
|
import {
|
|
38
38
|
__name
|
|
39
39
|
} from "./chunk-3GQAWCBQ.js";
|
|
@@ -274,7 +274,7 @@ var getConfigFile = /* @__PURE__ */ __name(async (filePath, additionalFileNames
|
|
|
274
274
|
}
|
|
275
275
|
}
|
|
276
276
|
}
|
|
277
|
-
if (!config) {
|
|
277
|
+
if (!config || Object.keys(config).length === 0) {
|
|
278
278
|
return void 0;
|
|
279
279
|
}
|
|
280
280
|
config.configFile = configFile;
|
|
@@ -748,7 +748,7 @@ var setBaseThemeColorConfigEnv = /* @__PURE__ */ __name((prefix, config) => {
|
|
|
748
748
|
// ../config-tools/src/create-storm-config.ts
|
|
749
749
|
var _extension_cache = /* @__PURE__ */ new WeakMap();
|
|
750
750
|
var _static_cache = void 0;
|
|
751
|
-
var createStormWorkspaceConfig = /* @__PURE__ */ __name(async (extensionName, schema, workspaceRoot, skipLogs = false) => {
|
|
751
|
+
var createStormWorkspaceConfig = /* @__PURE__ */ __name(async (extensionName, schema, workspaceRoot, skipLogs = false, useDefault = true) => {
|
|
752
752
|
let result;
|
|
753
753
|
if (!_static_cache?.data || !_static_cache?.timestamp || _static_cache.timestamp < Date.now() - 8e3) {
|
|
754
754
|
let _workspaceRoot = workspaceRoot;
|
|
@@ -756,13 +756,18 @@ var createStormWorkspaceConfig = /* @__PURE__ */ __name(async (extensionName, sc
|
|
|
756
756
|
_workspaceRoot = findWorkspaceRoot();
|
|
757
757
|
}
|
|
758
758
|
const configEnv = getConfigEnv();
|
|
759
|
-
const defaultConfig = await getDefaultConfig(_workspaceRoot);
|
|
760
759
|
const configFile = await getConfigFile(_workspaceRoot);
|
|
761
|
-
if (!configFile
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
760
|
+
if (!configFile) {
|
|
761
|
+
if (!skipLogs) {
|
|
762
|
+
writeWarning("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", {
|
|
763
|
+
logLevel: "all"
|
|
764
|
+
});
|
|
765
|
+
}
|
|
766
|
+
if (useDefault === false) {
|
|
767
|
+
return void 0;
|
|
768
|
+
}
|
|
765
769
|
}
|
|
770
|
+
const defaultConfig = await getDefaultConfig(_workspaceRoot);
|
|
766
771
|
result = await stormWorkspaceConfigSchema.parseAsync(defu2(configEnv, configFile, defaultConfig));
|
|
767
772
|
result.workspaceRoot ??= _workspaceRoot;
|
|
768
773
|
} else {
|
|
@@ -795,7 +800,7 @@ var createConfigExtension = /* @__PURE__ */ __name((extensionName, schema) => {
|
|
|
795
800
|
return extension;
|
|
796
801
|
}, "createConfigExtension");
|
|
797
802
|
var loadStormWorkspaceConfig = /* @__PURE__ */ __name(async (workspaceRoot, skipLogs = false) => {
|
|
798
|
-
const config = await createStormWorkspaceConfig(void 0, void 0, workspaceRoot, skipLogs);
|
|
803
|
+
const config = await createStormWorkspaceConfig(void 0, void 0, workspaceRoot, skipLogs, true);
|
|
799
804
|
setConfigEnv(config);
|
|
800
805
|
if (!skipLogs && !config.skipConfigLogging) {
|
|
801
806
|
writeTrace(`\u2699\uFE0F Using Storm Workspace configuration:
|
|
@@ -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
|
|
3
|
+
var _chunkPWE7CANFcjs = require('./chunk-PWE7CANF.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
var _chunkBGYQAVKQcjs = require('./chunk-BGYQAVKQ.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
|
-
|
|
35
|
+
_chunkPWE7CANFcjs.writeTrace.call(void 0, compilerOptions, config);
|
|
36
36
|
return compilerOptions;
|
|
37
37
|
}
|
|
38
38
|
_chunkBGYQAVKQcjs.__name.call(void 0, createTsCompilerOptions, "createTsCompilerOptions");
|
|
@@ -368,7 +368,7 @@ var stormWorkspaceConfigSchema = _zod2.default.object({
|
|
|
368
368
|
"staging",
|
|
369
369
|
"production"
|
|
370
370
|
]).default("production").describe("The current runtime environment mode for the package"),
|
|
371
|
-
workspaceRoot: _zod2.default.string().trim().
|
|
371
|
+
workspaceRoot: _zod2.default.string().trim().describe("The root directory of the workspace"),
|
|
372
372
|
externalPackagePatterns: _zod2.default.array(_zod2.default.string()).default([]).describe("The build will use these package patterns to determine if they should be external to the bundle"),
|
|
373
373
|
skipCache: _zod2.default.boolean().default(false).describe("Should all known types of workspace caching be skipped?"),
|
|
374
374
|
directories: WorkspaceDirectoryConfigSchema,
|
|
@@ -1,16 +1,16 @@
|
|
|
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 _chunkITHOVA3Dcjs = require('./chunk-ITHOVA3D.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
var
|
|
6
|
+
var _chunk3BXXHK3Fcjs = require('./chunk-3BXXHK3F.cjs');
|
|
7
7
|
|
|
8
8
|
|
|
9
|
-
var
|
|
9
|
+
var _chunkF4MPFQDIcjs = require('./chunk-F4MPFQDI.cjs');
|
|
10
10
|
|
|
11
11
|
|
|
12
12
|
|
|
13
|
-
var
|
|
13
|
+
var _chunkNVI74UAFcjs = require('./chunk-NVI74UAF.cjs');
|
|
14
14
|
|
|
15
15
|
|
|
16
16
|
|
|
@@ -33,7 +33,7 @@ var _chunkHEBZFJ2Ncjs = require('./chunk-HEBZFJ2N.cjs');
|
|
|
33
33
|
|
|
34
34
|
|
|
35
35
|
|
|
36
|
-
var
|
|
36
|
+
var _chunkPWE7CANFcjs = require('./chunk-PWE7CANF.cjs');
|
|
37
37
|
|
|
38
38
|
|
|
39
39
|
var _chunkBGYQAVKQcjs = require('./chunk-BGYQAVKQ.cjs');
|
|
@@ -86,8 +86,8 @@ var copyAssets = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, async (co
|
|
|
86
86
|
output: "src/"
|
|
87
87
|
});
|
|
88
88
|
}
|
|
89
|
-
|
|
90
|
-
${pendingAssets.map((pendingAsset) => typeof pendingAsset === "string" ? ` - ${pendingAsset} -> ${outputPath}` : ` - ${pendingAsset.input}/${pendingAsset.glob} -> ${
|
|
89
|
+
_chunkPWE7CANFcjs.writeTrace.call(void 0, `\u{1F4DD} Copying the following assets to the output directory:
|
|
90
|
+
${pendingAssets.map((pendingAsset) => typeof pendingAsset === "string" ? ` - ${pendingAsset} -> ${outputPath}` : ` - ${pendingAsset.input}/${pendingAsset.glob} -> ${_chunkPWE7CANFcjs.joinPaths.call(void 0, outputPath, pendingAsset.output)}`).join("\n")}`, config);
|
|
91
91
|
const assetHandler = new (0, _copyassetshandler.CopyAssetsHandler)({
|
|
92
92
|
projectDir: projectRoot,
|
|
93
93
|
rootDir: config.workspaceRoot,
|
|
@@ -96,12 +96,12 @@ ${pendingAssets.map((pendingAsset) => typeof pendingAsset === "string" ? ` - ${p
|
|
|
96
96
|
});
|
|
97
97
|
await assetHandler.processAllAssetsOnce();
|
|
98
98
|
if (includeSrc === true) {
|
|
99
|
-
|
|
99
|
+
_chunkPWE7CANFcjs.writeDebug.call(void 0, `\u{1F4DD} Adding banner and writing source files: ${_chunkPWE7CANFcjs.joinPaths.call(void 0, outputPath, "src")}`, config);
|
|
100
100
|
const files = await _glob.glob.call(void 0, [
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
101
|
+
_chunkPWE7CANFcjs.joinPaths.call(void 0, config.workspaceRoot, outputPath, "src/**/*.ts"),
|
|
102
|
+
_chunkPWE7CANFcjs.joinPaths.call(void 0, config.workspaceRoot, outputPath, "src/**/*.tsx"),
|
|
103
|
+
_chunkPWE7CANFcjs.joinPaths.call(void 0, config.workspaceRoot, outputPath, "src/**/*.js"),
|
|
104
|
+
_chunkPWE7CANFcjs.joinPaths.call(void 0, config.workspaceRoot, outputPath, "src/**/*.jsx")
|
|
105
105
|
]);
|
|
106
106
|
await Promise.allSettled(files.map(async (file) => _promises.writeFile.call(void 0, file, `${banner && typeof banner === "string" ? banner.startsWith("//") ? banner : `// ${banner}` : ""}
|
|
107
107
|
|
|
@@ -124,7 +124,7 @@ var addPackageDependencies = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void
|
|
|
124
124
|
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)) {
|
|
125
125
|
const projectNode = project.node;
|
|
126
126
|
if (projectNode.data.root) {
|
|
127
|
-
const projectPackageJsonPath =
|
|
127
|
+
const projectPackageJsonPath = _chunkPWE7CANFcjs.joinPaths.call(void 0, workspaceRoot, projectNode.data.root, "package.json");
|
|
128
128
|
if (_fs.existsSync.call(void 0, projectPackageJsonPath)) {
|
|
129
129
|
const projectPackageJsonContent = await _promises.readFile.call(void 0, projectPackageJsonPath, "utf8");
|
|
130
130
|
const projectPackageJson = JSON.parse(projectPackageJsonContent);
|
|
@@ -135,8 +135,8 @@ var addPackageDependencies = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void
|
|
|
135
135
|
}
|
|
136
136
|
}
|
|
137
137
|
if (localPackages.length > 0) {
|
|
138
|
-
|
|
139
|
-
const projectJsonFile = await _promises.readFile.call(void 0,
|
|
138
|
+
_chunkPWE7CANFcjs.writeTrace.call(void 0, `\u{1F4E6} Adding local packages to package.json: ${localPackages.map((p) => p.name).join(", ")}`);
|
|
139
|
+
const projectJsonFile = await _promises.readFile.call(void 0, _chunkPWE7CANFcjs.joinPaths.call(void 0, projectRoot, "project.json"), "utf8");
|
|
140
140
|
const projectJson = JSON.parse(projectJsonFile);
|
|
141
141
|
const projectName2 = projectJson.name;
|
|
142
142
|
const projectConfigurations = _projectgraph.readProjectsConfigurationFromProjectGraph.call(void 0, projectGraph);
|
|
@@ -145,7 +145,7 @@ var addPackageDependencies = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void
|
|
|
145
145
|
}
|
|
146
146
|
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) => {
|
|
147
147
|
if (_optionalChain([projectConfigurations, 'access', _14 => _14.projects, 'optionalAccess', _15 => _15[dep]])) {
|
|
148
|
-
const depPackageJsonPath =
|
|
148
|
+
const depPackageJsonPath = _chunkPWE7CANFcjs.joinPaths.call(void 0, workspaceRoot, projectConfigurations.projects[dep].root, "package.json");
|
|
149
149
|
if (_fs.existsSync.call(void 0, depPackageJsonPath)) {
|
|
150
150
|
const depPackageJsonContent = _fs.readFileSync.call(void 0, depPackageJsonPath, "utf8");
|
|
151
151
|
const depPackageJson = JSON.parse(depPackageJsonContent);
|
|
@@ -169,13 +169,13 @@ var addPackageDependencies = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void
|
|
|
169
169
|
return ret;
|
|
170
170
|
}, _nullishCoalesce(packageJson.devDependencies, () => ( {})));
|
|
171
171
|
} else {
|
|
172
|
-
|
|
172
|
+
_chunkPWE7CANFcjs.writeTrace.call(void 0, "\u{1F4E6} No local packages dependencies to add to package.json");
|
|
173
173
|
}
|
|
174
174
|
return packageJson;
|
|
175
175
|
}, "addPackageDependencies");
|
|
176
176
|
var addWorkspacePackageJsonFields = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, async (config, projectRoot, sourceRoot, projectName, includeSrc = false, packageJson) => {
|
|
177
|
-
const workspaceRoot = config.workspaceRoot ? config.workspaceRoot :
|
|
178
|
-
const workspacePackageJsonContent = await _promises.readFile.call(void 0,
|
|
177
|
+
const workspaceRoot = config.workspaceRoot ? config.workspaceRoot : _chunkPWE7CANFcjs.findWorkspaceRoot.call(void 0, );
|
|
178
|
+
const workspacePackageJsonContent = await _promises.readFile.call(void 0, _chunkPWE7CANFcjs.joinPaths.call(void 0, workspaceRoot, "package.json"), "utf8");
|
|
179
179
|
const workspacePackageJson = JSON.parse(workspacePackageJsonContent);
|
|
180
180
|
packageJson.type ??= "module";
|
|
181
181
|
packageJson.sideEffects ??= false;
|
|
@@ -184,7 +184,7 @@ var addWorkspacePackageJsonFields = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.cal
|
|
|
184
184
|
if (distSrc.startsWith("/")) {
|
|
185
185
|
distSrc = distSrc.substring(1);
|
|
186
186
|
}
|
|
187
|
-
packageJson.source ??= `${
|
|
187
|
+
packageJson.source ??= `${_chunkPWE7CANFcjs.joinPaths.call(void 0, distSrc, "index.ts").replaceAll("\\", "/")}`;
|
|
188
188
|
}
|
|
189
189
|
packageJson.files ??= [
|
|
190
190
|
"dist/**/*"
|
|
@@ -215,7 +215,7 @@ var addWorkspacePackageJsonFields = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.cal
|
|
|
215
215
|
];
|
|
216
216
|
}
|
|
217
217
|
packageJson.repository ??= workspacePackageJson.repository;
|
|
218
|
-
packageJson.repository.directory ??= projectRoot ? projectRoot :
|
|
218
|
+
packageJson.repository.directory ??= projectRoot ? projectRoot : _chunkPWE7CANFcjs.joinPaths.call(void 0, "packages", projectName);
|
|
219
219
|
return packageJson;
|
|
220
220
|
}, "addWorkspacePackageJsonFields");
|
|
221
221
|
|
|
@@ -223,7 +223,7 @@ var addWorkspacePackageJsonFields = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.cal
|
|
|
223
223
|
var _c12 = require('c12');
|
|
224
224
|
var _defu = require('defu'); var _defu2 = _interopRequireDefault(_defu);
|
|
225
225
|
var getConfigFileByName = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, async (fileName, filePath, options = {}) => {
|
|
226
|
-
const workspacePath = filePath ||
|
|
226
|
+
const workspacePath = filePath || _chunkPWE7CANFcjs.findWorkspaceRoot.call(void 0, filePath);
|
|
227
227
|
const configs = await Promise.all([
|
|
228
228
|
_c12.loadConfig.call(void 0, {
|
|
229
229
|
cwd: workspacePath,
|
|
@@ -232,7 +232,7 @@ var getConfigFileByName = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0,
|
|
|
232
232
|
envName: _optionalChain([fileName, 'optionalAccess', _24 => _24.toUpperCase, 'call', _25 => _25()]),
|
|
233
233
|
jitiOptions: {
|
|
234
234
|
debug: false,
|
|
235
|
-
fsCache: process.env.STORM_SKIP_CACHE === "true" ? false :
|
|
235
|
+
fsCache: process.env.STORM_SKIP_CACHE === "true" ? false : _chunkPWE7CANFcjs.joinPaths.call(void 0, process.env.STORM_CACHE_DIR || "node_modules/.cache/storm", "jiti")
|
|
236
236
|
},
|
|
237
237
|
...options
|
|
238
238
|
}),
|
|
@@ -243,7 +243,7 @@ var getConfigFileByName = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0,
|
|
|
243
243
|
envName: _optionalChain([fileName, 'optionalAccess', _26 => _26.toUpperCase, 'call', _27 => _27()]),
|
|
244
244
|
jitiOptions: {
|
|
245
245
|
debug: false,
|
|
246
|
-
fsCache: process.env.STORM_SKIP_CACHE === "true" ? false :
|
|
246
|
+
fsCache: process.env.STORM_SKIP_CACHE === "true" ? false : _chunkPWE7CANFcjs.joinPaths.call(void 0, process.env.STORM_CACHE_DIR || "node_modules/.cache/storm", "jiti")
|
|
247
247
|
},
|
|
248
248
|
configFile: fileName,
|
|
249
249
|
...options
|
|
@@ -252,12 +252,12 @@ var getConfigFileByName = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0,
|
|
|
252
252
|
return _defu2.default.call(void 0, _nullishCoalesce(configs[0], () => ( {})), _nullishCoalesce(configs[1], () => ( {})));
|
|
253
253
|
}, "getConfigFileByName");
|
|
254
254
|
var getConfigFile = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, async (filePath, additionalFileNames = []) => {
|
|
255
|
-
const workspacePath = filePath ? filePath :
|
|
255
|
+
const workspacePath = filePath ? filePath : _chunkPWE7CANFcjs.findWorkspaceRoot.call(void 0, filePath);
|
|
256
256
|
const result = await getConfigFileByName("storm-workspace", workspacePath);
|
|
257
257
|
let config = result.config;
|
|
258
258
|
const configFile = result.configFile;
|
|
259
259
|
if (config && configFile && Object.keys(config).length > 0 && !config.skipConfigLogging) {
|
|
260
|
-
|
|
260
|
+
_chunkPWE7CANFcjs.writeTrace.call(void 0, `Found Storm configuration file "${configFile.includes(`${workspacePath}/`) ? configFile.replace(`${workspacePath}/`, "") : configFile}" at "${workspacePath}"`, {
|
|
261
261
|
logLevel: "all"
|
|
262
262
|
});
|
|
263
263
|
}
|
|
@@ -266,7 +266,7 @@ var getConfigFile = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, async
|
|
|
266
266
|
for (const result2 of results) {
|
|
267
267
|
if (_optionalChain([result2, 'optionalAccess', _28 => _28.config]) && _optionalChain([result2, 'optionalAccess', _29 => _29.configFile]) && Object.keys(result2.config).length > 0) {
|
|
268
268
|
if (!config.skipConfigLogging && !result2.config.skipConfigLogging) {
|
|
269
|
-
|
|
269
|
+
_chunkPWE7CANFcjs.writeTrace.call(void 0, `Found alternative configuration file "${result2.configFile.includes(`${workspacePath}/`) ? result2.configFile.replace(`${workspacePath}/`, "") : result2.configFile}" at "${workspacePath}"`, {
|
|
270
270
|
logLevel: "all"
|
|
271
271
|
});
|
|
272
272
|
}
|
|
@@ -274,7 +274,7 @@ var getConfigFile = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, async
|
|
|
274
274
|
}
|
|
275
275
|
}
|
|
276
276
|
}
|
|
277
|
-
if (!config) {
|
|
277
|
+
if (!config || Object.keys(config).length === 0) {
|
|
278
278
|
return void 0;
|
|
279
279
|
}
|
|
280
280
|
config.configFile = configFile;
|
|
@@ -332,15 +332,15 @@ var getConfigEnv = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, () => {
|
|
|
332
332
|
contact: process.env[`${prefix}CONTACT`] || void 0,
|
|
333
333
|
timezone: process.env[`${prefix}TIMEZONE`] || process.env.TZ || void 0,
|
|
334
334
|
locale: process.env[`${prefix}LOCALE`] || process.env.LOCALE || void 0,
|
|
335
|
-
configFile: process.env[`${prefix}CONFIG_FILE`] ?
|
|
336
|
-
workspaceRoot: process.env[`${prefix}WORKSPACE_ROOT`] ?
|
|
335
|
+
configFile: process.env[`${prefix}CONFIG_FILE`] ? _chunkPWE7CANFcjs.correctPaths.call(void 0, process.env[`${prefix}CONFIG_FILE`]) : void 0,
|
|
336
|
+
workspaceRoot: process.env[`${prefix}WORKSPACE_ROOT`] ? _chunkPWE7CANFcjs.correctPaths.call(void 0, process.env[`${prefix}WORKSPACE_ROOT`]) : void 0,
|
|
337
337
|
directories: {
|
|
338
|
-
cache: process.env[`${prefix}CACHE_DIR`] ?
|
|
339
|
-
data: process.env[`${prefix}DATA_DIR`] ?
|
|
340
|
-
config: process.env[`${prefix}CONFIG_DIR`] ?
|
|
341
|
-
temp: process.env[`${prefix}TEMP_DIR`] ?
|
|
342
|
-
log: process.env[`${prefix}LOG_DIR`] ?
|
|
343
|
-
build: process.env[`${prefix}BUILD_DIR`] ?
|
|
338
|
+
cache: process.env[`${prefix}CACHE_DIR`] ? _chunkPWE7CANFcjs.correctPaths.call(void 0, process.env[`${prefix}CACHE_DIR`]) : process.env[`${prefix}CACHE_DIRECTORY`] ? _chunkPWE7CANFcjs.correctPaths.call(void 0, process.env[`${prefix}CACHE_DIRECTORY`]) : void 0,
|
|
339
|
+
data: process.env[`${prefix}DATA_DIR`] ? _chunkPWE7CANFcjs.correctPaths.call(void 0, process.env[`${prefix}DATA_DIR`]) : process.env[`${prefix}DATA_DIRECTORY`] ? _chunkPWE7CANFcjs.correctPaths.call(void 0, process.env[`${prefix}DATA_DIRECTORY`]) : void 0,
|
|
340
|
+
config: process.env[`${prefix}CONFIG_DIR`] ? _chunkPWE7CANFcjs.correctPaths.call(void 0, process.env[`${prefix}CONFIG_DIR`]) : process.env[`${prefix}CONFIG_DIRECTORY`] ? _chunkPWE7CANFcjs.correctPaths.call(void 0, process.env[`${prefix}CONFIG_DIRECTORY`]) : void 0,
|
|
341
|
+
temp: process.env[`${prefix}TEMP_DIR`] ? _chunkPWE7CANFcjs.correctPaths.call(void 0, process.env[`${prefix}TEMP_DIR`]) : process.env[`${prefix}TEMP_DIRECTORY`] ? _chunkPWE7CANFcjs.correctPaths.call(void 0, process.env[`${prefix}TEMP_DIRECTORY`]) : void 0,
|
|
342
|
+
log: process.env[`${prefix}LOG_DIR`] ? _chunkPWE7CANFcjs.correctPaths.call(void 0, process.env[`${prefix}LOG_DIR`]) : process.env[`${prefix}LOG_DIRECTORY`] ? _chunkPWE7CANFcjs.correctPaths.call(void 0, process.env[`${prefix}LOG_DIRECTORY`]) : void 0,
|
|
343
|
+
build: process.env[`${prefix}BUILD_DIR`] ? _chunkPWE7CANFcjs.correctPaths.call(void 0, process.env[`${prefix}BUILD_DIR`]) : process.env[`${prefix}BUILD_DIRECTORY`] ? _chunkPWE7CANFcjs.correctPaths.call(void 0, process.env[`${prefix}BUILD_DIRECTORY`]) : void 0
|
|
344
344
|
},
|
|
345
345
|
skipCache: process.env[`${prefix}SKIP_CACHE`] !== void 0 ? Boolean(process.env[`${prefix}SKIP_CACHE`]) : void 0,
|
|
346
346
|
mode: (_nullishCoalesce(_nullishCoalesce(process.env[`${prefix}MODE`], () => ( process.env.NODE_ENV)), () => ( process.env.ENVIRONMENT))) || void 0,
|
|
@@ -363,24 +363,24 @@ var getConfigEnv = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, () => {
|
|
|
363
363
|
cyclone: process.env[`${prefix}REGISTRY_CYCLONE`] || void 0,
|
|
364
364
|
container: process.env[`${prefix}REGISTRY_CONTAINER`] || void 0
|
|
365
365
|
},
|
|
366
|
-
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`])) ?
|
|
366
|
+
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`])) ? _chunkPWE7CANFcjs.getLogLevelLabel.call(void 0, Number.parseInt(process.env[`${prefix}LOG_LEVEL`])) : process.env[`${prefix}LOG_LEVEL`] : void 0,
|
|
367
367
|
skipConfigLogging: process.env[`${prefix}SKIP_CONFIG_LOGGING`] !== void 0 ? Boolean(process.env[`${prefix}SKIP_CONFIG_LOGGING`]) : void 0
|
|
368
368
|
};
|
|
369
|
-
const themeNames = Object.keys(process.env).filter((envKey) => envKey.startsWith(`${prefix}COLOR_`) &&
|
|
369
|
+
const themeNames = Object.keys(process.env).filter((envKey) => envKey.startsWith(`${prefix}COLOR_`) && _chunkPWE7CANFcjs.COLOR_KEYS.every((colorKey) => !envKey.startsWith(`${prefix}COLOR_LIGHT_${colorKey}`) && !envKey.startsWith(`${prefix}COLOR_DARK_${colorKey}`)));
|
|
370
370
|
config.colors = themeNames.length > 0 ? themeNames.reduce((ret, themeName) => {
|
|
371
371
|
ret[themeName] = getThemeColorConfigEnv(prefix, themeName);
|
|
372
372
|
return ret;
|
|
373
373
|
}, {}) : getThemeColorConfigEnv(prefix);
|
|
374
|
-
if (config.docs ===
|
|
375
|
-
if (config.homepage ===
|
|
376
|
-
config.docs = `${
|
|
374
|
+
if (config.docs === _chunkPWE7CANFcjs.STORM_DEFAULT_DOCS) {
|
|
375
|
+
if (config.homepage === _chunkPWE7CANFcjs.STORM_DEFAULT_HOMEPAGE) {
|
|
376
|
+
config.docs = `${_chunkPWE7CANFcjs.STORM_DEFAULT_HOMEPAGE}/projects/${config.name}/docs`;
|
|
377
377
|
} else {
|
|
378
378
|
config.docs = `${config.homepage}/docs`;
|
|
379
379
|
}
|
|
380
380
|
}
|
|
381
|
-
if (config.licensing ===
|
|
382
|
-
if (config.homepage ===
|
|
383
|
-
config.licensing = `${
|
|
381
|
+
if (config.licensing === _chunkPWE7CANFcjs.STORM_DEFAULT_LICENSING) {
|
|
382
|
+
if (config.homepage === _chunkPWE7CANFcjs.STORM_DEFAULT_HOMEPAGE) {
|
|
383
|
+
config.licensing = `${_chunkPWE7CANFcjs.STORM_DEFAULT_HOMEPAGE}/projects/${config.name}/licensing`;
|
|
384
384
|
} else {
|
|
385
385
|
config.licensing = `${config.homepage}/docs`;
|
|
386
386
|
}
|
|
@@ -550,36 +550,36 @@ var setConfigEnv = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, (config
|
|
|
550
550
|
process.env.LANG = config.locale ? `${config.locale.replaceAll("-", "_")}.UTF-8` : "en_US.UTF-8";
|
|
551
551
|
}
|
|
552
552
|
if (config.configFile) {
|
|
553
|
-
process.env[`${prefix}CONFIG_FILE`] =
|
|
553
|
+
process.env[`${prefix}CONFIG_FILE`] = _chunkPWE7CANFcjs.correctPaths.call(void 0, config.configFile);
|
|
554
554
|
}
|
|
555
555
|
if (config.workspaceRoot) {
|
|
556
|
-
process.env[`${prefix}WORKSPACE_ROOT`] =
|
|
557
|
-
process.env.NX_WORKSPACE_ROOT =
|
|
558
|
-
process.env.NX_WORKSPACE_ROOT_PATH =
|
|
556
|
+
process.env[`${prefix}WORKSPACE_ROOT`] = _chunkPWE7CANFcjs.correctPaths.call(void 0, config.workspaceRoot);
|
|
557
|
+
process.env.NX_WORKSPACE_ROOT = _chunkPWE7CANFcjs.correctPaths.call(void 0, config.workspaceRoot);
|
|
558
|
+
process.env.NX_WORKSPACE_ROOT_PATH = _chunkPWE7CANFcjs.correctPaths.call(void 0, config.workspaceRoot);
|
|
559
559
|
}
|
|
560
560
|
if (config.directories) {
|
|
561
561
|
if (!config.skipCache && config.directories.cache) {
|
|
562
|
-
process.env[`${prefix}CACHE_DIR`] =
|
|
562
|
+
process.env[`${prefix}CACHE_DIR`] = _chunkPWE7CANFcjs.correctPaths.call(void 0, config.directories.cache);
|
|
563
563
|
process.env[`${prefix}CACHE_DIRECTORY`] = process.env[`${prefix}CACHE_DIR`];
|
|
564
564
|
}
|
|
565
565
|
if (config.directories.data) {
|
|
566
|
-
process.env[`${prefix}DATA_DIR`] =
|
|
566
|
+
process.env[`${prefix}DATA_DIR`] = _chunkPWE7CANFcjs.correctPaths.call(void 0, config.directories.data);
|
|
567
567
|
process.env[`${prefix}DATA_DIRECTORY`] = process.env[`${prefix}DATA_DIR`];
|
|
568
568
|
}
|
|
569
569
|
if (config.directories.config) {
|
|
570
|
-
process.env[`${prefix}CONFIG_DIR`] =
|
|
570
|
+
process.env[`${prefix}CONFIG_DIR`] = _chunkPWE7CANFcjs.correctPaths.call(void 0, config.directories.config);
|
|
571
571
|
process.env[`${prefix}CONFIG_DIRECTORY`] = process.env[`${prefix}CONFIG_DIR`];
|
|
572
572
|
}
|
|
573
573
|
if (config.directories.temp) {
|
|
574
|
-
process.env[`${prefix}TEMP_DIR`] =
|
|
574
|
+
process.env[`${prefix}TEMP_DIR`] = _chunkPWE7CANFcjs.correctPaths.call(void 0, config.directories.temp);
|
|
575
575
|
process.env[`${prefix}TEMP_DIRECTORY`] = process.env[`${prefix}TEMP_DIR`];
|
|
576
576
|
}
|
|
577
577
|
if (config.directories.log) {
|
|
578
|
-
process.env[`${prefix}LOG_DIR`] =
|
|
578
|
+
process.env[`${prefix}LOG_DIR`] = _chunkPWE7CANFcjs.correctPaths.call(void 0, config.directories.log);
|
|
579
579
|
process.env[`${prefix}LOG_DIRECTORY`] = process.env[`${prefix}LOG_DIR`];
|
|
580
580
|
}
|
|
581
581
|
if (config.directories.build) {
|
|
582
|
-
process.env[`${prefix}BUILD_DIR`] =
|
|
582
|
+
process.env[`${prefix}BUILD_DIR`] = _chunkPWE7CANFcjs.correctPaths.call(void 0, config.directories.build);
|
|
583
583
|
process.env[`${prefix}BUILD_DIRECTORY`] = process.env[`${prefix}BUILD_DIR`];
|
|
584
584
|
}
|
|
585
585
|
}
|
|
@@ -634,8 +634,8 @@ var setConfigEnv = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, (config
|
|
|
634
634
|
if (config.logLevel) {
|
|
635
635
|
process.env[`${prefix}LOG_LEVEL`] = String(config.logLevel);
|
|
636
636
|
process.env.LOG_LEVEL = String(config.logLevel);
|
|
637
|
-
process.env.NX_VERBOSE_LOGGING = String(
|
|
638
|
-
process.env.RUST_BACKTRACE =
|
|
637
|
+
process.env.NX_VERBOSE_LOGGING = String(_chunkPWE7CANFcjs.getLogLevel.call(void 0, config.logLevel) >= _chunkPWE7CANFcjs.LogLevel.DEBUG ? true : false);
|
|
638
|
+
process.env.RUST_BACKTRACE = _chunkPWE7CANFcjs.getLogLevel.call(void 0, config.logLevel) >= _chunkPWE7CANFcjs.LogLevel.DEBUG ? "full" : "none";
|
|
639
639
|
}
|
|
640
640
|
if (config.skipConfigLogging !== void 0) {
|
|
641
641
|
process.env[`${prefix}SKIP_CONFIG_LOGGING`] = String(config.skipConfigLogging);
|
|
@@ -748,22 +748,27 @@ var setBaseThemeColorConfigEnv = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(v
|
|
|
748
748
|
// ../config-tools/src/create-storm-config.ts
|
|
749
749
|
var _extension_cache = /* @__PURE__ */ new WeakMap();
|
|
750
750
|
var _static_cache = void 0;
|
|
751
|
-
var createStormWorkspaceConfig = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, async (extensionName, schema, workspaceRoot, skipLogs = false) => {
|
|
751
|
+
var createStormWorkspaceConfig = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, async (extensionName, schema, workspaceRoot, skipLogs = false, useDefault = true) => {
|
|
752
752
|
let result;
|
|
753
753
|
if (!_optionalChain([_static_cache, 'optionalAccess', _52 => _52.data]) || !_optionalChain([_static_cache, 'optionalAccess', _53 => _53.timestamp]) || _static_cache.timestamp < Date.now() - 8e3) {
|
|
754
754
|
let _workspaceRoot = workspaceRoot;
|
|
755
755
|
if (!_workspaceRoot) {
|
|
756
|
-
_workspaceRoot =
|
|
756
|
+
_workspaceRoot = _chunkPWE7CANFcjs.findWorkspaceRoot.call(void 0, );
|
|
757
757
|
}
|
|
758
758
|
const configEnv = getConfigEnv();
|
|
759
|
-
const defaultConfig = await _chunkOFV7JN7Ocjs.getDefaultConfig.call(void 0, _workspaceRoot);
|
|
760
759
|
const configFile = await getConfigFile(_workspaceRoot);
|
|
761
|
-
if (!configFile
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
760
|
+
if (!configFile) {
|
|
761
|
+
if (!skipLogs) {
|
|
762
|
+
_chunkPWE7CANFcjs.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", {
|
|
763
|
+
logLevel: "all"
|
|
764
|
+
});
|
|
765
|
+
}
|
|
766
|
+
if (useDefault === false) {
|
|
767
|
+
return void 0;
|
|
768
|
+
}
|
|
765
769
|
}
|
|
766
|
-
|
|
770
|
+
const defaultConfig = await _chunkPWE7CANFcjs.getDefaultConfig.call(void 0, _workspaceRoot);
|
|
771
|
+
result = await _chunkPWE7CANFcjs.stormWorkspaceConfigSchema.parseAsync(_defu2.default.call(void 0, configEnv, configFile, defaultConfig));
|
|
767
772
|
result.workspaceRoot ??= _workspaceRoot;
|
|
768
773
|
} else {
|
|
769
774
|
result = _static_cache.data;
|
|
@@ -795,11 +800,11 @@ var createConfigExtension = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0
|
|
|
795
800
|
return extension;
|
|
796
801
|
}, "createConfigExtension");
|
|
797
802
|
var loadStormWorkspaceConfig = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, async (workspaceRoot, skipLogs = false) => {
|
|
798
|
-
const config = await createStormWorkspaceConfig(void 0, void 0, workspaceRoot, skipLogs);
|
|
803
|
+
const config = await createStormWorkspaceConfig(void 0, void 0, workspaceRoot, skipLogs, true);
|
|
799
804
|
setConfigEnv(config);
|
|
800
805
|
if (!skipLogs && !config.skipConfigLogging) {
|
|
801
|
-
|
|
802
|
-
${
|
|
806
|
+
_chunkPWE7CANFcjs.writeTrace.call(void 0, `\u2699\uFE0F Using Storm Workspace configuration:
|
|
807
|
+
${_chunkPWE7CANFcjs.formatLogMessage.call(void 0, config)}`, config);
|
|
803
808
|
}
|
|
804
809
|
return config;
|
|
805
810
|
}, "loadStormWorkspaceConfig");
|
|
@@ -828,24 +833,24 @@ var _createtaskgraph = require('nx/src/tasks-runner/create-task-graph');
|
|
|
828
833
|
var _findworkspaceroot = require('nx/src/utils/find-workspace-root');
|
|
829
834
|
var _unbuild = require('unbuild');
|
|
830
835
|
async function resolveOptions(options, config) {
|
|
831
|
-
|
|
832
|
-
const stopwatch =
|
|
836
|
+
_chunkPWE7CANFcjs.writeDebug.call(void 0, " \u2699\uFE0F Resolving build options", config);
|
|
837
|
+
const stopwatch = _chunkPWE7CANFcjs.getStopwatch.call(void 0, "Build options resolution");
|
|
833
838
|
if (options.configPath) {
|
|
834
|
-
const configFile = await
|
|
839
|
+
const configFile = await _chunkNVI74UAFcjs.loadConfig.call(void 0, options.configPath);
|
|
835
840
|
if (configFile) {
|
|
836
841
|
options = _defu2.default.call(void 0, options, configFile);
|
|
837
842
|
}
|
|
838
843
|
}
|
|
839
|
-
const outputPath = options.outputPath ||
|
|
844
|
+
const outputPath = options.outputPath || _chunkPWE7CANFcjs.joinPaths.call(void 0, "dist", options.projectRoot);
|
|
840
845
|
const projectGraph = _devkit.readCachedProjectGraph.call(void 0, );
|
|
841
|
-
const projectJsonPath =
|
|
846
|
+
const projectJsonPath = _chunkPWE7CANFcjs.joinPaths.call(void 0, config.workspaceRoot, options.projectRoot, "project.json");
|
|
842
847
|
if (!_fs.existsSync.call(void 0, projectJsonPath)) {
|
|
843
848
|
throw new Error("Cannot find project.json configuration");
|
|
844
849
|
}
|
|
845
850
|
const projectJsonContent = await _promises.readFile.call(void 0, projectJsonPath, "utf8");
|
|
846
851
|
const projectJson = JSON.parse(projectJsonContent);
|
|
847
852
|
const projectName = projectJson.name;
|
|
848
|
-
const packageJsonPath =
|
|
853
|
+
const packageJsonPath = _chunkPWE7CANFcjs.joinPaths.call(void 0, config.workspaceRoot, options.projectRoot, "package.json");
|
|
849
854
|
if (!_fs.existsSync.call(void 0, packageJsonPath)) {
|
|
850
855
|
throw new Error("Cannot find package.json configuration");
|
|
851
856
|
}
|
|
@@ -853,17 +858,17 @@ async function resolveOptions(options, config) {
|
|
|
853
858
|
const packageJson = JSON.parse(packageJsonContent);
|
|
854
859
|
let tsconfig = options.tsconfig;
|
|
855
860
|
if (!tsconfig) {
|
|
856
|
-
tsconfig =
|
|
861
|
+
tsconfig = _chunkPWE7CANFcjs.joinPaths.call(void 0, options.projectRoot, "tsconfig.json");
|
|
857
862
|
}
|
|
858
863
|
if (!tsconfig.startsWith(config.workspaceRoot)) {
|
|
859
|
-
tsconfig =
|
|
864
|
+
tsconfig = _chunkPWE7CANFcjs.joinPaths.call(void 0, config.workspaceRoot, tsconfig);
|
|
860
865
|
}
|
|
861
866
|
if (!_fs.existsSync.call(void 0, tsconfig)) {
|
|
862
867
|
throw new Error("Cannot find tsconfig.json configuration");
|
|
863
868
|
}
|
|
864
869
|
let sourceRoot = projectJson.sourceRoot;
|
|
865
870
|
if (!sourceRoot) {
|
|
866
|
-
sourceRoot =
|
|
871
|
+
sourceRoot = _chunkPWE7CANFcjs.joinPaths.call(void 0, options.projectRoot, "src");
|
|
867
872
|
}
|
|
868
873
|
if (!_fs.existsSync.call(void 0, sourceRoot)) {
|
|
869
874
|
throw new Error("Cannot find sourceRoot directory");
|
|
@@ -898,7 +903,7 @@ async function resolveOptions(options, config) {
|
|
|
898
903
|
while (entryPath.startsWith("/")) {
|
|
899
904
|
entryPath = entryPath.substring(1);
|
|
900
905
|
}
|
|
901
|
-
const outDir =
|
|
906
|
+
const outDir = _chunkPWE7CANFcjs.joinPaths.call(void 0, _path.relative.call(void 0, _chunkPWE7CANFcjs.joinPaths.call(void 0, config.workspaceRoot, options.projectRoot), config.workspaceRoot), outputPath, "dist");
|
|
902
907
|
ret.push({
|
|
903
908
|
name: `${name}-esm`,
|
|
904
909
|
builder: "mkdist",
|
|
@@ -972,7 +977,7 @@ async function resolveOptions(options, config) {
|
|
|
972
977
|
treeShaking: options.treeShaking !== false,
|
|
973
978
|
platform: options.platform || "neutral",
|
|
974
979
|
color: true,
|
|
975
|
-
logLevel: config.logLevel ===
|
|
980
|
+
logLevel: config.logLevel === _chunkPWE7CANFcjs.LogLevelLabel.FATAL ? _chunkPWE7CANFcjs.LogLevelLabel.ERROR : _chunkPWE7CANFcjs.isVerbose.call(void 0, ) ? "verbose" : config.logLevel
|
|
976
981
|
}
|
|
977
982
|
}
|
|
978
983
|
};
|
|
@@ -989,7 +994,7 @@ async function resolveOptions(options, config) {
|
|
|
989
994
|
if (options.rollup) {
|
|
990
995
|
let rollup = {};
|
|
991
996
|
if (typeof options.rollup === "string") {
|
|
992
|
-
const rollupFile = await
|
|
997
|
+
const rollupFile = await _chunkNVI74UAFcjs.loadConfig.call(void 0, options.rollup);
|
|
993
998
|
if (rollupFile) {
|
|
994
999
|
rollup = rollupFile;
|
|
995
1000
|
}
|
|
@@ -1001,14 +1006,14 @@ async function resolveOptions(options, config) {
|
|
|
1001
1006
|
resolvedOptions.hooks = {
|
|
1002
1007
|
"rollup:options": /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0, async (ctx, opts) => {
|
|
1003
1008
|
if (options.plugins && options.plugins.length > 0) {
|
|
1004
|
-
|
|
1009
|
+
_chunkPWE7CANFcjs.writeDebug.call(void 0, ` \u{1F9E9} Found ${options.plugins.length} plugins in provided build options`, config);
|
|
1005
1010
|
opts.plugins = options.plugins;
|
|
1006
1011
|
} else {
|
|
1007
|
-
|
|
1012
|
+
_chunkPWE7CANFcjs.writeDebug.call(void 0, ` \u{1F9E9} No plugins found in provided build options, using default plugins`, config);
|
|
1008
1013
|
opts.plugins = await Promise.all([
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
|
|
1014
|
+
_chunk3BXXHK3Fcjs.analyzePlugin.call(void 0, resolvedOptions),
|
|
1015
|
+
_chunkNVI74UAFcjs.tscPlugin.call(void 0, resolvedOptions),
|
|
1016
|
+
_chunkF4MPFQDIcjs.onErrorPlugin.call(void 0, resolvedOptions)
|
|
1012
1017
|
]);
|
|
1013
1018
|
}
|
|
1014
1019
|
}, "rollup:options"),
|
|
@@ -1061,14 +1066,14 @@ var addPackageJsonExport = /* @__PURE__ */ _chunkBGYQAVKQcjs.__name.call(void 0,
|
|
|
1061
1066
|
};
|
|
1062
1067
|
}, "addPackageJsonExport");
|
|
1063
1068
|
async function generatePackageJson(options) {
|
|
1064
|
-
if (options.generatePackageJson !== false && _fs.existsSync.call(void 0,
|
|
1065
|
-
|
|
1066
|
-
const stopwatch =
|
|
1067
|
-
const packageJsonPath =
|
|
1069
|
+
if (options.generatePackageJson !== false && _fs.existsSync.call(void 0, _chunkPWE7CANFcjs.joinPaths.call(void 0, options.projectRoot, "package.json"))) {
|
|
1070
|
+
_chunkPWE7CANFcjs.writeDebug.call(void 0, " \u270D\uFE0F Writing package.json file", options.config);
|
|
1071
|
+
const stopwatch = _chunkPWE7CANFcjs.getStopwatch.call(void 0, "Write package.json file");
|
|
1072
|
+
const packageJsonPath = _chunkPWE7CANFcjs.joinPaths.call(void 0, options.projectRoot, "project.json");
|
|
1068
1073
|
if (!_fs.existsSync.call(void 0, packageJsonPath)) {
|
|
1069
1074
|
throw new Error("Cannot find package.json configuration");
|
|
1070
1075
|
}
|
|
1071
|
-
const packageJsonContent = await _promises.readFile.call(void 0,
|
|
1076
|
+
const packageJsonContent = await _promises.readFile.call(void 0, _chunkPWE7CANFcjs.joinPaths.call(void 0, options.config.workspaceRoot, options.projectRoot, "package.json"), "utf8");
|
|
1072
1077
|
if (!packageJsonContent) {
|
|
1073
1078
|
throw new Error("Cannot find package.json configuration file");
|
|
1074
1079
|
}
|
|
@@ -1085,7 +1090,7 @@ async function generatePackageJson(options) {
|
|
|
1085
1090
|
while (entryPath.startsWith("/")) {
|
|
1086
1091
|
entryPath = entryPath.substring(1);
|
|
1087
1092
|
}
|
|
1088
|
-
entryPath = `./${
|
|
1093
|
+
entryPath = `./${_chunkPWE7CANFcjs.joinPaths.call(void 0, options.projectRoot, entryPath)}`;
|
|
1089
1094
|
if (!ret.includes(entryPath)) {
|
|
1090
1095
|
ret.push(entryPath);
|
|
1091
1096
|
}
|
|
@@ -1116,23 +1121,23 @@ async function generatePackageJson(options) {
|
|
|
1116
1121
|
}, packageJson.exports);
|
|
1117
1122
|
packageJson.exports["./package.json"] ??= "./package.json";
|
|
1118
1123
|
packageJson.exports["."] ??= addPackageJsonExport("index", packageJson.type, options.sourceRoot, options.projectRoot);
|
|
1119
|
-
await _devkit.writeJsonFile.call(void 0,
|
|
1124
|
+
await _devkit.writeJsonFile.call(void 0, _chunkPWE7CANFcjs.joinPaths.call(void 0, options.outDir, "package.json"), packageJson);
|
|
1120
1125
|
stopwatch();
|
|
1121
1126
|
}
|
|
1122
1127
|
return options;
|
|
1123
1128
|
}
|
|
1124
1129
|
_chunkBGYQAVKQcjs.__name.call(void 0, generatePackageJson, "generatePackageJson");
|
|
1125
1130
|
async function executeUnbuild(options) {
|
|
1126
|
-
|
|
1127
|
-
const stopwatch =
|
|
1131
|
+
_chunkPWE7CANFcjs.writeDebug.call(void 0, ` \u{1F680} Running ${options.name} (${options.projectRoot}) build`, options.config);
|
|
1132
|
+
const stopwatch = _chunkPWE7CANFcjs.getStopwatch.call(void 0, `${options.name} (${options.projectRoot}) build`);
|
|
1128
1133
|
try {
|
|
1129
1134
|
const config = {
|
|
1130
1135
|
...options,
|
|
1131
1136
|
config: null,
|
|
1132
|
-
rootDir:
|
|
1137
|
+
rootDir: _chunkPWE7CANFcjs.joinPaths.call(void 0, options.config.workspaceRoot, options.projectRoot)
|
|
1133
1138
|
};
|
|
1134
|
-
|
|
1135
|
-
${
|
|
1139
|
+
_chunkPWE7CANFcjs.writeTrace.call(void 0, `Running with unbuild configuration:
|
|
1140
|
+
${_chunkPWE7CANFcjs.formatLogMessage.call(void 0, {
|
|
1136
1141
|
...config,
|
|
1137
1142
|
env: "<Hidden>"
|
|
1138
1143
|
})}
|
|
@@ -1145,8 +1150,8 @@ ${_chunkOFV7JN7Ocjs.formatLogMessage.call(void 0, {
|
|
|
1145
1150
|
}
|
|
1146
1151
|
_chunkBGYQAVKQcjs.__name.call(void 0, executeUnbuild, "executeUnbuild");
|
|
1147
1152
|
async function copyBuildAssets(options) {
|
|
1148
|
-
|
|
1149
|
-
const stopwatch =
|
|
1153
|
+
_chunkPWE7CANFcjs.writeDebug.call(void 0, ` \u{1F4CB} Copying asset files to output directory: ${options.outDir}`, options.config);
|
|
1154
|
+
const stopwatch = _chunkPWE7CANFcjs.getStopwatch.call(void 0, `${options.name} asset copy`);
|
|
1150
1155
|
await copyAssets(options.config, _nullishCoalesce(options.assets, () => ( [])), options.outDir, options.projectRoot, options.sourceRoot, options.generatePackageJson, options.includeSrc);
|
|
1151
1156
|
stopwatch();
|
|
1152
1157
|
return options;
|
|
@@ -1154,9 +1159,9 @@ async function copyBuildAssets(options) {
|
|
|
1154
1159
|
_chunkBGYQAVKQcjs.__name.call(void 0, copyBuildAssets, "copyBuildAssets");
|
|
1155
1160
|
async function cleanOutputPath(options) {
|
|
1156
1161
|
if (options.clean !== false && options.outDir) {
|
|
1157
|
-
|
|
1158
|
-
const stopwatch =
|
|
1159
|
-
await
|
|
1162
|
+
_chunkPWE7CANFcjs.writeDebug.call(void 0, ` \u{1F9F9} Cleaning ${options.name} output path: ${options.outDir}`, options.config);
|
|
1163
|
+
const stopwatch = _chunkPWE7CANFcjs.getStopwatch.call(void 0, `${options.name} output clean`);
|
|
1164
|
+
await _chunkITHOVA3Dcjs.cleanDirectories.call(void 0, options.name, options.outDir, options.config);
|
|
1160
1165
|
stopwatch();
|
|
1161
1166
|
}
|
|
1162
1167
|
return options;
|
|
@@ -1172,10 +1177,10 @@ async function build(options) {
|
|
|
1172
1177
|
throw new Error("Cannot find workspace root");
|
|
1173
1178
|
}
|
|
1174
1179
|
const config = await getConfig(workspaceRoot.dir);
|
|
1175
|
-
|
|
1176
|
-
const stopwatch =
|
|
1180
|
+
_chunkPWE7CANFcjs.writeDebug.call(void 0, ` \u26A1 Executing Storm Unbuild pipeline`, config);
|
|
1181
|
+
const stopwatch = _chunkPWE7CANFcjs.getStopwatch.call(void 0, "Unbuild pipeline");
|
|
1177
1182
|
try {
|
|
1178
|
-
options.projectRoot =
|
|
1183
|
+
options.projectRoot = _chunkPWE7CANFcjs.correctPaths.call(void 0, projectRoot);
|
|
1179
1184
|
const resolvedOptions = await resolveOptions(options, config);
|
|
1180
1185
|
await cleanOutputPath(resolvedOptions);
|
|
1181
1186
|
if (options.buildOnly !== true) {
|
|
@@ -1185,9 +1190,9 @@ async function build(options) {
|
|
|
1185
1190
|
if (options.buildOnly !== true) {
|
|
1186
1191
|
await copyBuildAssets(resolvedOptions);
|
|
1187
1192
|
}
|
|
1188
|
-
|
|
1193
|
+
_chunkPWE7CANFcjs.writeSuccess.call(void 0, ` \u{1F3C1} The ${resolvedOptions.name} build completed successfully`, config);
|
|
1189
1194
|
} catch (error) {
|
|
1190
|
-
|
|
1195
|
+
_chunkPWE7CANFcjs.writeFatal.call(void 0, "Fatal errors that the build process could not recover from have occured. The build process has been terminated.", config);
|
|
1191
1196
|
throw error;
|
|
1192
1197
|
} finally {
|
|
1193
1198
|
stopwatch();
|
package/dist/clean.cjs
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
5
|
-
require('./chunk-
|
|
4
|
+
var _chunkITHOVA3Dcjs = require('./chunk-ITHOVA3D.cjs');
|
|
5
|
+
require('./chunk-PWE7CANF.cjs');
|
|
6
6
|
require('./chunk-BGYQAVKQ.cjs');
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
|
|
10
|
-
exports.clean =
|
|
10
|
+
exports.clean = _chunkITHOVA3Dcjs.clean; exports.cleanDirectories = _chunkITHOVA3Dcjs.cleanDirectories;
|
package/dist/clean.js
CHANGED
package/dist/index.cjs
CHANGED
|
@@ -5,19 +5,19 @@
|
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
|
|
8
|
-
var
|
|
8
|
+
var _chunkYIDTYRQYcjs = require('./chunk-YIDTYRQY.cjs');
|
|
9
9
|
|
|
10
10
|
|
|
11
11
|
|
|
12
|
-
var
|
|
12
|
+
var _chunkITHOVA3Dcjs = require('./chunk-ITHOVA3D.cjs');
|
|
13
13
|
require('./chunk-ORA4UQMU.cjs');
|
|
14
|
-
require('./chunk-
|
|
15
|
-
require('./chunk-
|
|
14
|
+
require('./chunk-3BXXHK3F.cjs');
|
|
15
|
+
require('./chunk-F4MPFQDI.cjs');
|
|
16
16
|
|
|
17
17
|
|
|
18
18
|
|
|
19
|
-
var
|
|
20
|
-
require('./chunk-
|
|
19
|
+
var _chunkNVI74UAFcjs = require('./chunk-NVI74UAF.cjs');
|
|
20
|
+
require('./chunk-PWE7CANF.cjs');
|
|
21
21
|
require('./chunk-BGYQAVKQ.cjs');
|
|
22
22
|
|
|
23
23
|
|
|
@@ -30,4 +30,4 @@ require('./chunk-BGYQAVKQ.cjs');
|
|
|
30
30
|
|
|
31
31
|
|
|
32
32
|
|
|
33
|
-
exports.build =
|
|
33
|
+
exports.build = _chunkYIDTYRQYcjs.build; exports.clean = _chunkITHOVA3Dcjs.clean; exports.cleanDirectories = _chunkITHOVA3Dcjs.cleanDirectories; exports.cleanOutputPath = _chunkYIDTYRQYcjs.cleanOutputPath; exports.copyBuildAssets = _chunkYIDTYRQYcjs.copyBuildAssets; exports.createTsCompilerOptions = _chunkNVI74UAFcjs.createTsCompilerOptions; exports.executeUnbuild = _chunkYIDTYRQYcjs.executeUnbuild; exports.generatePackageJson = _chunkYIDTYRQYcjs.generatePackageJson; exports.loadConfig = _chunkNVI74UAFcjs.loadConfig; exports.resolveOptions = _chunkYIDTYRQYcjs.resolveOptions;
|
package/dist/index.js
CHANGED
|
@@ -5,19 +5,19 @@ import {
|
|
|
5
5
|
executeUnbuild,
|
|
6
6
|
generatePackageJson,
|
|
7
7
|
resolveOptions
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-J4UJGE35.js";
|
|
9
9
|
import {
|
|
10
10
|
clean,
|
|
11
11
|
cleanDirectories
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-DUDE4LYM.js";
|
|
13
13
|
import "./chunk-OULCUN6I.js";
|
|
14
|
-
import "./chunk-
|
|
15
|
-
import "./chunk-
|
|
14
|
+
import "./chunk-SMAV5VSP.js";
|
|
15
|
+
import "./chunk-HZNOKNKE.js";
|
|
16
16
|
import {
|
|
17
17
|
createTsCompilerOptions,
|
|
18
18
|
loadConfig
|
|
19
|
-
} from "./chunk-
|
|
20
|
-
import "./chunk-
|
|
19
|
+
} from "./chunk-2PUJT7MC.js";
|
|
20
|
+
import "./chunk-3BDIPKMO.js";
|
|
21
21
|
import "./chunk-3GQAWCBQ.js";
|
|
22
22
|
export {
|
|
23
23
|
build,
|
package/dist/plugins/analyze.cjs
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
require('../chunk-
|
|
3
|
+
var _chunk3BXXHK3Fcjs = require('../chunk-3BXXHK3F.cjs');
|
|
4
|
+
require('../chunk-PWE7CANF.cjs');
|
|
5
5
|
require('../chunk-BGYQAVKQ.cjs');
|
|
6
6
|
|
|
7
7
|
|
|
8
|
-
exports.analyzePlugin =
|
|
8
|
+
exports.analyzePlugin = _chunk3BXXHK3Fcjs.analyzePlugin;
|
package/dist/plugins/analyze.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
require('../chunk-
|
|
3
|
+
var _chunkF4MPFQDIcjs = require('../chunk-F4MPFQDI.cjs');
|
|
4
|
+
require('../chunk-PWE7CANF.cjs');
|
|
5
5
|
require('../chunk-BGYQAVKQ.cjs');
|
|
6
6
|
|
|
7
7
|
|
|
8
|
-
exports.onErrorPlugin =
|
|
8
|
+
exports.onErrorPlugin = _chunkF4MPFQDIcjs.onErrorPlugin;
|
package/dist/plugins/on-error.js
CHANGED
package/dist/plugins/tsc.cjs
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
require('../chunk-
|
|
3
|
+
var _chunkNVI74UAFcjs = require('../chunk-NVI74UAF.cjs');
|
|
4
|
+
require('../chunk-PWE7CANF.cjs');
|
|
5
5
|
require('../chunk-BGYQAVKQ.cjs');
|
|
6
6
|
|
|
7
7
|
|
|
8
|
-
exports.tscPlugin =
|
|
8
|
+
exports.tscPlugin = _chunkNVI74UAFcjs.tscPlugin;
|
package/dist/plugins/tsc.js
CHANGED
package/package.json
CHANGED