@storm-software/unbuild 0.55.2 → 0.55.4
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/unbuild.cjs +1 -1
- package/bin/unbuild.js +1 -1
- package/dist/build.cjs +2 -2
- package/dist/build.js +1 -1
- package/dist/{chunk-IE44IJPR.cjs → chunk-DVONFKXX.cjs} +19 -19
- package/dist/{chunk-GMJ7A3ZF.js → chunk-FWPMRRS5.js} +1 -1
- package/dist/index.cjs +2 -2
- package/dist/index.js +1 -1
- package/package.json +5 -5
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/unbuild.cjs
CHANGED
|
@@ -920,7 +920,7 @@ var correctPaths = function(path2) {
|
|
|
920
920
|
return ".";
|
|
921
921
|
}
|
|
922
922
|
path2 = normalizeWindowsPath(path2);
|
|
923
|
-
const isUNCPath = path2
|
|
923
|
+
const isUNCPath = path2?.match(_UNC_REGEX);
|
|
924
924
|
const isPathAbsolute = isAbsolute(path2);
|
|
925
925
|
const trailingSeparator = path2[path2.length - 1] === "/";
|
|
926
926
|
path2 = normalizeString(path2, !isPathAbsolute);
|
package/bin/unbuild.js
CHANGED
|
@@ -898,7 +898,7 @@ var correctPaths = function(path2) {
|
|
|
898
898
|
return ".";
|
|
899
899
|
}
|
|
900
900
|
path2 = normalizeWindowsPath(path2);
|
|
901
|
-
const isUNCPath = path2
|
|
901
|
+
const isUNCPath = path2?.match(_UNC_REGEX);
|
|
902
902
|
const isPathAbsolute = isAbsolute(path2);
|
|
903
903
|
const trailingSeparator = path2[path2.length - 1] === "/";
|
|
904
904
|
path2 = normalizeString(path2, !isPathAbsolute);
|
package/dist/build.cjs
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
|
|
8
|
-
var
|
|
8
|
+
var _chunkDVONFKXXcjs = require('./chunk-DVONFKXX.cjs');
|
|
9
9
|
require('./chunk-5LYLEQEH.cjs');
|
|
10
10
|
require('./chunk-XYM4DLHB.cjs');
|
|
11
11
|
require('./chunk-ULVTNQE3.cjs');
|
|
@@ -19,4 +19,4 @@ require('./chunk-OBGZSXTJ.cjs');
|
|
|
19
19
|
|
|
20
20
|
|
|
21
21
|
|
|
22
|
-
exports.build =
|
|
22
|
+
exports.build = _chunkDVONFKXXcjs.build; exports.cleanOutputPath = _chunkDVONFKXXcjs.cleanOutputPath; exports.copyBuildAssets = _chunkDVONFKXXcjs.copyBuildAssets; exports.executeUnbuild = _chunkDVONFKXXcjs.executeUnbuild; exports.generatePackageJson = _chunkDVONFKXXcjs.generatePackageJson; exports.resolveOptions = _chunkDVONFKXXcjs.resolveOptions;
|
package/dist/build.js
CHANGED
|
@@ -67,7 +67,7 @@ var correctPaths = function(path2) {
|
|
|
67
67
|
return ".";
|
|
68
68
|
}
|
|
69
69
|
path2 = normalizeWindowsPath(path2);
|
|
70
|
-
const isUNCPath = path2.match(_UNC_REGEX);
|
|
70
|
+
const isUNCPath = _optionalChain([path2, 'optionalAccess', _ => _.match, 'call', _2 => _2(_UNC_REGEX)]);
|
|
71
71
|
const isPathAbsolute = isAbsolute(path2);
|
|
72
72
|
const trailingSeparator = path2[path2.length - 1] === "/";
|
|
73
73
|
path2 = normalizeString(path2, !isPathAbsolute);
|
|
@@ -377,7 +377,7 @@ var addPackageDependencies = async (workspaceRoot, projectRoot, projectName, pac
|
|
|
377
377
|
);
|
|
378
378
|
const localPackages = [];
|
|
379
379
|
for (const project of projectDependencies.dependencies.filter(
|
|
380
|
-
(dep) => dep.node.type === "lib" && _optionalChain([dep, 'access',
|
|
380
|
+
(dep) => dep.node.type === "lib" && _optionalChain([dep, 'access', _3 => _3.node, 'access', _4 => _4.data, 'optionalAccess', _5 => _5.root]) !== projectRoot && _optionalChain([dep, 'access', _6 => _6.node, 'access', _7 => _7.data, 'optionalAccess', _8 => _8.root]) !== workspaceRoot
|
|
381
381
|
)) {
|
|
382
382
|
const projectNode = project.node;
|
|
383
383
|
if (projectNode.data.root) {
|
|
@@ -409,13 +409,13 @@ var addPackageDependencies = async (workspaceRoot, projectRoot, projectName, pac
|
|
|
409
409
|
const projectJson = JSON.parse(projectJsonFile);
|
|
410
410
|
const projectName2 = projectJson.name;
|
|
411
411
|
const projectConfigurations = _projectgraph.readProjectsConfigurationFromProjectGraph.call(void 0, projectGraph);
|
|
412
|
-
if (!_optionalChain([projectConfigurations, 'optionalAccess',
|
|
412
|
+
if (!_optionalChain([projectConfigurations, 'optionalAccess', _9 => _9.projects, 'optionalAccess', _10 => _10[projectName2]])) {
|
|
413
413
|
throw new Error(
|
|
414
414
|
"The Build process failed because the project does not have a valid configuration in the project.json file. Check if the file exists in the root of the project."
|
|
415
415
|
);
|
|
416
416
|
}
|
|
417
|
-
const implicitDependencies = _optionalChain([projectConfigurations, 'access',
|
|
418
|
-
if (_optionalChain([projectConfigurations, 'access',
|
|
417
|
+
const implicitDependencies = _optionalChain([projectConfigurations, 'access', _11 => _11.projects, 'optionalAccess', _12 => _12[projectName2], 'access', _13 => _13.implicitDependencies, 'optionalAccess', _14 => _14.reduce, 'call', _15 => _15((ret, dep) => {
|
|
418
|
+
if (_optionalChain([projectConfigurations, 'access', _16 => _16.projects, 'optionalAccess', _17 => _17[dep]])) {
|
|
419
419
|
const depPackageJsonPath = joinPaths(
|
|
420
420
|
workspaceRoot,
|
|
421
421
|
projectConfigurations.projects[dep].root,
|
|
@@ -435,13 +435,13 @@ var addPackageDependencies = async (workspaceRoot, projectRoot, projectName, pac
|
|
|
435
435
|
return ret;
|
|
436
436
|
}, [])]);
|
|
437
437
|
packageJson.dependencies = localPackages.reduce((ret, localPackage) => {
|
|
438
|
-
if (!ret[localPackage.name] && !_optionalChain([implicitDependencies, 'optionalAccess',
|
|
438
|
+
if (!ret[localPackage.name] && !_optionalChain([implicitDependencies, 'optionalAccess', _18 => _18.includes, 'call', _19 => _19(localPackage.name)]) && _optionalChain([packageJson, 'access', _20 => _20.devDependencies, 'optionalAccess', _21 => _21[localPackage.name]]) === void 0) {
|
|
439
439
|
ret[localPackage.name] = `^${localPackage.version || "0.0.1"}`;
|
|
440
440
|
}
|
|
441
441
|
return ret;
|
|
442
442
|
}, _nullishCoalesce(packageJson.dependencies, () => ( {})));
|
|
443
443
|
packageJson.devDependencies = localPackages.reduce((ret, localPackage) => {
|
|
444
|
-
if (!ret[localPackage.name] && _optionalChain([implicitDependencies, 'optionalAccess',
|
|
444
|
+
if (!ret[localPackage.name] && _optionalChain([implicitDependencies, 'optionalAccess', _22 => _22.includes, 'call', _23 => _23(localPackage.name)]) && _optionalChain([packageJson, 'access', _24 => _24.dependencies, 'optionalAccess', _25 => _25[localPackage.name]]) === void 0) {
|
|
445
445
|
ret[localPackage.name] = `^${localPackage.version || "0.0.1"}`;
|
|
446
446
|
}
|
|
447
447
|
return ret;
|
|
@@ -1166,7 +1166,7 @@ function applyDefaultConfig(config) {
|
|
|
1166
1166
|
if (!config.contact) {
|
|
1167
1167
|
config.contact = `${config.homepage}/contact`;
|
|
1168
1168
|
}
|
|
1169
|
-
if (!_optionalChain([config, 'access',
|
|
1169
|
+
if (!_optionalChain([config, 'access', _26 => _26.error, 'optionalAccess', _27 => _27.codesFile]) || !_optionalChain([config, 'optionalAccess', _28 => _28.error, 'optionalAccess', _29 => _29.url])) {
|
|
1170
1170
|
config.error ??= { codesFile: STORM_DEFAULT_ERROR_CODES_FILE };
|
|
1171
1171
|
if (config.homepage) {
|
|
1172
1172
|
config.error.url ??= `${config.homepage}/errors`;
|
|
@@ -1184,7 +1184,7 @@ var getConfigFileByName = async (fileName, filePath, options = {}) => {
|
|
|
1184
1184
|
cwd: workspacePath,
|
|
1185
1185
|
packageJson: true,
|
|
1186
1186
|
name: fileName,
|
|
1187
|
-
envName: _optionalChain([fileName, 'optionalAccess',
|
|
1187
|
+
envName: _optionalChain([fileName, 'optionalAccess', _30 => _30.toUpperCase, 'call', _31 => _31()]),
|
|
1188
1188
|
jitiOptions: {
|
|
1189
1189
|
debug: false,
|
|
1190
1190
|
fsCache: process.env.STORM_SKIP_CACHE === "true" ? false : joinPaths(
|
|
@@ -1198,7 +1198,7 @@ var getConfigFileByName = async (fileName, filePath, options = {}) => {
|
|
|
1198
1198
|
cwd: workspacePath,
|
|
1199
1199
|
packageJson: true,
|
|
1200
1200
|
name: fileName,
|
|
1201
|
-
envName: _optionalChain([fileName, 'optionalAccess',
|
|
1201
|
+
envName: _optionalChain([fileName, 'optionalAccess', _32 => _32.toUpperCase, 'call', _33 => _33()]),
|
|
1202
1202
|
jitiOptions: {
|
|
1203
1203
|
debug: false,
|
|
1204
1204
|
fsCache: process.env.STORM_SKIP_CACHE === "true" ? false : joinPaths(
|
|
@@ -1232,7 +1232,7 @@ var getConfigFile = async (filePath, additionalFileNames = []) => {
|
|
|
1232
1232
|
)
|
|
1233
1233
|
);
|
|
1234
1234
|
for (const result2 of results) {
|
|
1235
|
-
if (_optionalChain([result2, 'optionalAccess',
|
|
1235
|
+
if (_optionalChain([result2, 'optionalAccess', _34 => _34.config]) && _optionalChain([result2, 'optionalAccess', _35 => _35.configFile]) && Object.keys(result2.config).length > 0) {
|
|
1236
1236
|
if (!config.skipConfigLogging && !result2.config.skipConfigLogging) {
|
|
1237
1237
|
_chunkKRY2I44Jcjs.writeTrace.call(void 0,
|
|
1238
1238
|
`Found alternative configuration file "${result2.configFile.includes(`${workspacePath}/`) ? result2.configFile.replace(`${workspacePath}/`, "") : result2.configFile}" at "${workspacePath}"`,
|
|
@@ -1471,16 +1471,16 @@ var getBaseThemeColorsEnv = (prefix) => {
|
|
|
1471
1471
|
var setExtensionEnv = (extensionName, extension) => {
|
|
1472
1472
|
for (const key of Object.keys(_nullishCoalesce(extension, () => ( {})))) {
|
|
1473
1473
|
if (extension[key]) {
|
|
1474
|
-
const result = _nullishCoalesce(_optionalChain([key, 'optionalAccess',
|
|
1474
|
+
const result = _nullishCoalesce(_optionalChain([key, 'optionalAccess', _36 => _36.replace, 'call', _37 => _37(
|
|
1475
1475
|
/([A-Z])+/g,
|
|
1476
|
-
(input) => input ? _optionalChain([input, 'access',
|
|
1477
|
-
), 'access',
|
|
1476
|
+
(input) => input ? _optionalChain([input, 'access', _38 => _38[0], 'optionalAccess', _39 => _39.toUpperCase, 'call', _40 => _40()]) + input.slice(1) : ""
|
|
1477
|
+
), 'access', _41 => _41.split, 'call', _42 => _42(/(?=[A-Z])|[.\-\s_]/), 'access', _43 => _43.map, 'call', _44 => _44((x) => x.toLowerCase())]), () => ( []));
|
|
1478
1478
|
let extensionKey;
|
|
1479
1479
|
if (result.length === 0) {
|
|
1480
1480
|
return;
|
|
1481
1481
|
}
|
|
1482
1482
|
if (result.length === 1) {
|
|
1483
|
-
extensionKey = _nullishCoalesce(_optionalChain([result, 'access',
|
|
1483
|
+
extensionKey = _nullishCoalesce(_optionalChain([result, 'access', _45 => _45[0], 'optionalAccess', _46 => _46.toUpperCase, 'call', _47 => _47()]), () => ( ""));
|
|
1484
1484
|
} else {
|
|
1485
1485
|
extensionKey = result.reduce((ret, part) => {
|
|
1486
1486
|
return `${ret}_${part.toLowerCase()}`;
|
|
@@ -1668,7 +1668,7 @@ var setConfigEnv = (config) => {
|
|
|
1668
1668
|
process.env.NODE_ENV = config.mode;
|
|
1669
1669
|
process.env.ENVIRONMENT = config.mode;
|
|
1670
1670
|
}
|
|
1671
|
-
if (_optionalChain([config, 'access',
|
|
1671
|
+
if (_optionalChain([config, 'access', _48 => _48.colors, 'optionalAccess', _49 => _49.base, 'optionalAccess', _50 => _50.light]) || _optionalChain([config, 'access', _51 => _51.colors, 'optionalAccess', _52 => _52.base, 'optionalAccess', _53 => _53.dark])) {
|
|
1672
1672
|
for (const key of Object.keys(config.colors)) {
|
|
1673
1673
|
setThemeColorsEnv(`${prefix}COLOR_${key}_`, config.colors[key]);
|
|
1674
1674
|
}
|
|
@@ -1729,7 +1729,7 @@ var setConfigEnv = (config) => {
|
|
|
1729
1729
|
}
|
|
1730
1730
|
};
|
|
1731
1731
|
var setThemeColorsEnv = (prefix, config) => {
|
|
1732
|
-
return _optionalChain([config, 'optionalAccess',
|
|
1732
|
+
return _optionalChain([config, 'optionalAccess', _54 => _54.light, 'optionalAccess', _55 => _55.brand]) || _optionalChain([config, 'optionalAccess', _56 => _56.dark, 'optionalAccess', _57 => _57.brand]) ? setMultiThemeColorsEnv(prefix, config) : setSingleThemeColorsEnv(prefix, config);
|
|
1733
1733
|
};
|
|
1734
1734
|
var setSingleThemeColorsEnv = (prefix, config) => {
|
|
1735
1735
|
if (config.dark) {
|
|
@@ -1841,7 +1841,7 @@ var _extension_cache = /* @__PURE__ */ new WeakMap();
|
|
|
1841
1841
|
var _static_cache = void 0;
|
|
1842
1842
|
var createStormWorkspaceConfig = async (extensionName, schema, workspaceRoot, skipLogs = false, useDefault = true) => {
|
|
1843
1843
|
let result;
|
|
1844
|
-
if (!_optionalChain([_static_cache, 'optionalAccess',
|
|
1844
|
+
if (!_optionalChain([_static_cache, 'optionalAccess', _58 => _58.data]) || !_optionalChain([_static_cache, 'optionalAccess', _59 => _59.timestamp]) || _static_cache.timestamp < Date.now() - 8e3) {
|
|
1845
1845
|
let _workspaceRoot = workspaceRoot;
|
|
1846
1846
|
if (!_workspaceRoot) {
|
|
1847
1847
|
_workspaceRoot = findWorkspaceRoot();
|
|
@@ -1872,7 +1872,7 @@ var createStormWorkspaceConfig = async (extensionName, schema, workspaceRoot, sk
|
|
|
1872
1872
|
result.workspaceRoot ??= _workspaceRoot;
|
|
1873
1873
|
} catch (error) {
|
|
1874
1874
|
throw new Error(
|
|
1875
|
-
`Failed to parse Storm Workspace configuration${_optionalChain([error, 'optionalAccess',
|
|
1875
|
+
`Failed to parse Storm Workspace configuration${_optionalChain([error, 'optionalAccess', _60 => _60.message]) ? `: ${error.message}` : ""}
|
|
1876
1876
|
|
|
1877
1877
|
Please ensure your configuration file is valid JSON and matches the expected schema. The current workspace configuration input is: ${_chunkKRY2I44Jcjs.formatLogMessage.call(void 0,
|
|
1878
1878
|
configInput
|
|
@@ -67,7 +67,7 @@ var correctPaths = function(path2) {
|
|
|
67
67
|
return ".";
|
|
68
68
|
}
|
|
69
69
|
path2 = normalizeWindowsPath(path2);
|
|
70
|
-
const isUNCPath = path2
|
|
70
|
+
const isUNCPath = path2?.match(_UNC_REGEX);
|
|
71
71
|
const isPathAbsolute = isAbsolute(path2);
|
|
72
72
|
const trailingSeparator = path2[path2.length - 1] === "/";
|
|
73
73
|
path2 = normalizeString(path2, !isPathAbsolute);
|
package/dist/index.cjs
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
|
|
8
|
-
var
|
|
8
|
+
var _chunkDVONFKXXcjs = require('./chunk-DVONFKXX.cjs');
|
|
9
9
|
|
|
10
10
|
|
|
11
11
|
|
|
@@ -30,4 +30,4 @@ require('./chunk-OBGZSXTJ.cjs');
|
|
|
30
30
|
|
|
31
31
|
|
|
32
32
|
|
|
33
|
-
exports.build =
|
|
33
|
+
exports.build = _chunkDVONFKXXcjs.build; exports.clean = _chunk5LYLEQEHcjs.clean; exports.cleanDirectories = _chunk5LYLEQEHcjs.cleanDirectories; exports.cleanOutputPath = _chunkDVONFKXXcjs.cleanOutputPath; exports.copyBuildAssets = _chunkDVONFKXXcjs.copyBuildAssets; exports.createTsCompilerOptions = _chunkQRSVSWU2cjs.createTsCompilerOptions; exports.executeUnbuild = _chunkDVONFKXXcjs.executeUnbuild; exports.generatePackageJson = _chunkDVONFKXXcjs.generatePackageJson; exports.loadConfig = _chunkQRSVSWU2cjs.loadConfig; exports.resolveOptions = _chunkDVONFKXXcjs.resolveOptions;
|
package/dist/index.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@storm-software/unbuild",
|
|
3
|
-
"version": "0.55.
|
|
3
|
+
"version": "0.55.4",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "A package containing `unbuild` utilities for building Storm Software libraries and applications",
|
|
6
6
|
"repository": {
|
|
@@ -147,9 +147,9 @@
|
|
|
147
147
|
"typescript": { "optional": false }
|
|
148
148
|
},
|
|
149
149
|
"dependencies": {
|
|
150
|
-
"@storm-software/build-tools": "^0.155.
|
|
151
|
-
"@storm-software/config": "^1.131.
|
|
152
|
-
"@storm-software/config-tools": "^1.185.
|
|
150
|
+
"@storm-software/build-tools": "^0.155.4",
|
|
151
|
+
"@storm-software/config": "^1.131.4",
|
|
152
|
+
"@storm-software/config-tools": "^1.185.4",
|
|
153
153
|
"commander": "^12.1.0",
|
|
154
154
|
"defu": "6.1.4",
|
|
155
155
|
"esbuild": "^0.25.0",
|
|
@@ -171,5 +171,5 @@
|
|
|
171
171
|
},
|
|
172
172
|
"publishConfig": { "access": "public" },
|
|
173
173
|
"sideEffects": false,
|
|
174
|
-
"gitHead": "
|
|
174
|
+
"gitHead": "bf0e3ad2902fa0cd4613fe4896deea054a78a4be"
|
|
175
175
|
}
|