@storm-software/cloudflare-tools 0.71.244 → 0.71.247
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/CHANGELOG.md +36 -0
- package/README.md +1 -1
- package/dist/{chunk-NJOOPHBM.js → chunk-2SPQ64QX.js} +2 -2
- package/dist/{chunk-GWP7DME7.mjs → chunk-GYIUU2G4.mjs} +183 -141
- package/dist/{chunk-ZDGAILQ2.mjs → chunk-KZQP6DGG.mjs} +1 -1
- package/dist/{chunk-SNE4W7AT.mjs → chunk-MCCHKUCS.mjs} +1 -1
- package/dist/{chunk-6KQ5YG7A.mjs → chunk-NG5JLH7K.mjs} +2 -2
- package/dist/{chunk-I673VEX6.mjs → chunk-NZ4SP2BO.mjs} +1 -1
- package/dist/{chunk-UZX2DPHE.js → chunk-O6QQDVZ5.js} +2 -2
- package/dist/{chunk-4YG4DTJE.js → chunk-OTUOQHGH.js} +2 -2
- package/dist/{chunk-AWIMXPCE.js → chunk-UGIZ5QUS.js} +1 -1
- package/dist/{chunk-7NFFNXFN.js → chunk-XKZTXB5T.js} +163 -121
- package/dist/executors.js +1 -1
- package/dist/executors.mjs +1 -1
- package/dist/generators.js +3 -3
- package/dist/generators.mjs +2 -2
- package/dist/index.js +4 -4
- package/dist/index.mjs +3 -3
- package/dist/src/executors/cloudflare-publish/executor.js +1 -1
- package/dist/src/executors/cloudflare-publish/executor.mjs +1 -1
- package/dist/src/executors/serve/executor.js +2 -2
- package/dist/src/executors/serve/executor.mjs +1 -1
- package/dist/src/generators/init/generator.js +2 -2
- package/dist/src/generators/init/generator.mjs +1 -1
- package/dist/src/generators/worker/generator.js +3 -3
- package/dist/src/generators/worker/generator.mjs +2 -2
- package/package.json +6 -6
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); 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 _chunkUGIZ5QUSjs = require('./chunk-UGIZ5QUS.js');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
@@ -70,7 +70,7 @@ ${Object.keys(process.env).map((key) => ` - ${key}=${JSON.stringify(process.env[
|
|
|
70
70
|
const options = await normalizeOptions(tree, schema, config);
|
|
71
71
|
const tasks = [];
|
|
72
72
|
tasks.push(
|
|
73
|
-
await
|
|
73
|
+
await _chunkUGIZ5QUSjs.generator_default.call(void 0, tree, {
|
|
74
74
|
...options,
|
|
75
75
|
skipFormat: true
|
|
76
76
|
})
|
|
@@ -7,7 +7,7 @@ var require_package = _chunkMCKGQKYUjs.__commonJS.call(void 0, {
|
|
|
7
7
|
"package.json"(exports, module) {
|
|
8
8
|
module.exports = {
|
|
9
9
|
name: "@storm-software/cloudflare-tools",
|
|
10
|
-
version: "0.71.
|
|
10
|
+
version: "0.71.246",
|
|
11
11
|
private: false,
|
|
12
12
|
description: "A Nx plugin package that contains various executors, generators, and utilities that assist in managing Cloudflare services.",
|
|
13
13
|
keywords: [
|
|
@@ -180,7 +180,7 @@ var require_package = _chunkMCKGQKYUjs.__commonJS.call(void 0, {
|
|
|
180
180
|
nx: "catalog:",
|
|
181
181
|
tsup: "catalog:",
|
|
182
182
|
untyped: "catalog:",
|
|
183
|
-
wrangler: "^4.
|
|
183
|
+
wrangler: "^4.111.0"
|
|
184
184
|
},
|
|
185
185
|
peerDependencies: {
|
|
186
186
|
nx: ">=22.7.1",
|
|
@@ -5,7 +5,7 @@ var _chunkMCKGQKYUjs = require('./chunk-MCKGQKYU.js');
|
|
|
5
5
|
// package.json
|
|
6
6
|
var require_package = _chunkMCKGQKYUjs.__commonJS.call(void 0, {
|
|
7
7
|
"package.json"(exports, module) {
|
|
8
|
-
module.exports = { name: "@storm-software/cloudflare-tools", version: "0.71.
|
|
8
|
+
module.exports = { name: "@storm-software/cloudflare-tools", version: "0.71.247", private: false, description: "A Nx plugin package that contains various executors, generators, and utilities that assist in managing Cloudflare services.", keywords: ["monorepo", "open-system", "storm", "storm-ops", "storm-stack", "stormstack", "sullivanpj"], homepage: "https://stormsoftware.com", bugs: "https://github.com/storm-software/storm-ops/issues", repository: { type: "github", url: "https://github.com/storm-software/storm-ops.git", directory: "packages/cloudflare-tools" }, license: "Apache-2.0", author: { name: "Storm Software", email: "contact@stormsoftware.com", url: "https://stormsoftware.com" }, exports: { "./package.json": "./package.json", "./docs/*": "./docs/*", "./migrations.json": "./migrations.json", "./executors.json": "./executors.json", "./executors/*/schema.json": "./dist/src/executors/*/schema.json", "./generators.json": "./generators.json", "./generators/*/schema.json": "./dist/src/generators/*/schema.json", ".": { import: { types: "./dist/index.d.mts", default: "./dist/index.mjs" }, require: { types: "./dist/index.d.ts", default: "./dist/index.js" }, default: { types: "./dist/index.d.ts", default: "./dist/index.js" } }, "./index": { import: { types: "./dist/index.d.mts", default: "./dist/index.mjs" }, require: { types: "./dist/index.d.ts", default: "./dist/index.js" }, default: { types: "./dist/index.d.ts", default: "./dist/index.js" } }, "./executors": { import: { types: "./dist/executors.d.mts", default: "./dist/executors.mjs" }, require: { types: "./dist/executors.d.ts", default: "./dist/executors.js" }, default: { types: "./dist/executors.d.ts", default: "./dist/executors.js" } }, "./executors/*": { import: { types: "./dist/src/executors/*.d.mts", default: "./dist/src/executors/*.mjs" }, require: { types: "./dist/src/executors/*.d.ts", default: "./dist/src/executors/*.js" }, default: { types: "./dist/src/executors/*.d.ts", default: "./dist/src/executors/*.js" } }, "./generators": { import: { types: "./dist/generators.d.mts", default: "./dist/generators.mjs" }, require: { types: "./dist/generators.d.ts", default: "./dist/generators.js" }, default: { types: "./dist/generators.d.ts", default: "./dist/generators.js" } }, "./generators/*": { import: { types: "./dist/src/generators/*.d.mts", default: "./dist/src/generators/*.mjs" }, require: { types: "./dist/src/generators/*.d.ts", default: "./dist/src/generators/*.js" }, default: { types: "./dist/src/generators/*.d.ts", default: "./dist/src/generators/*.js" } }, "./utils": { import: { types: "./dist/src/utils/index.d.mts", default: "./dist/src/utils/index.mjs" }, require: { types: "./dist/src/utils/index.d.ts", default: "./dist/src/utils/index.js" }, default: { types: "./dist/src/utils/index.d.ts", default: "./dist/src/utils/index.js" } }, "./utils/*": { import: { types: "./dist/src/utils/*.d.mts", default: "./dist/src/utils/*.mjs" }, require: { types: "./dist/src/utils/*.d.ts", default: "./dist/src/utils/*.js" }, default: { types: "./dist/src/utils/*.d.ts", default: "./dist/src/utils/*.js" } }, "./executors/*/executor.js": "./dist/src/executors/*/executor.js", "./generators/*/generator.js": "./dist/src/generators/*/generator.js", "./plugin": "./dist/src/plugins/index.js" }, main: "dist/index.js", module: "dist/index.mjs", typings: "dist/index.d.ts", dependencies: { "@aws-sdk/client-s3": "^3.1087.0", "@aws-sdk/lib-storage": "^3.1087.0", "@smithy/node-http-handler": "^4.9.6", "@storm-software/config": "workspace:*", "@storm-software/config-tools": "workspace:*", "@storm-software/workspace-tools": "workspace:*", defu: "catalog:", glob: "catalog:", "mime-types": "^3.0.2", "pretty-bytes": "^7.1.0" }, devDependencies: { "@nx/devkit": "catalog:", "@nx/node": "catalog:", "@nx/web": "catalog:", "@nx/webpack": "catalog:", "@smithy/protocol-http": "^5.5.9", nx: "catalog:", tsup: "catalog:", untyped: "catalog:", wrangler: "^4.111.0" }, peerDependencies: { nx: ">=22.7.1", wrangler: ">=3.58.0" }, peerDependenciesMeta: { nx: { optional: false }, wrangler: { optional: false } }, publishConfig: { access: "public" }, executors: "./executors.json", generators: "./generators.json" };
|
|
9
9
|
}
|
|
10
10
|
});
|
|
11
11
|
|
|
@@ -627,38 +627,19 @@ var executor_default7 = withRunExecutor(
|
|
|
627
627
|
}
|
|
628
628
|
);
|
|
629
629
|
|
|
630
|
-
// ../
|
|
631
|
-
|
|
632
|
-
var _semver = require('semver');
|
|
633
|
-
var _stripansi = require('strip-ansi'); var _stripansi2 = _interopRequireDefault(_stripansi);
|
|
634
|
-
|
|
635
|
-
// ../npm-tools/src/helpers/get-registry.ts
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
// ../pnpm-tools/src/helpers/catalog.ts
|
|
639
|
-
|
|
630
|
+
// ../workspace-tools/src/executors/npm-publish/executor.ts
|
|
640
631
|
|
|
641
|
-
// ../pnpm-tools/src/helpers/pnpm-workspace.ts
|
|
642
632
|
|
|
643
633
|
var _promises = require('fs/promises'); var _promises2 = _interopRequireDefault(_promises);
|
|
644
|
-
var _yaml = require('yaml');
|
|
645
|
-
|
|
646
|
-
// ../pnpm-tools/src/helpers/replace-deps-aliases.ts
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
653
634
|
var _prettier = require('prettier');
|
|
654
635
|
|
|
655
|
-
// ../workspace-tools/src/
|
|
636
|
+
// ../workspace-tools/src/utils/github.ts
|
|
656
637
|
|
|
657
638
|
|
|
639
|
+
// ../workspace-tools/src/utils/package-manager.ts
|
|
658
640
|
|
|
659
641
|
|
|
660
642
|
|
|
661
|
-
// ../workspace-tools/src/utils/github.ts
|
|
662
643
|
|
|
663
644
|
|
|
664
645
|
// ../workspace-tools/src/executors/npm-publish/executor.ts
|
|
@@ -1029,15 +1010,15 @@ function getDefaultOptions(config) {
|
|
|
1029
1010
|
...config
|
|
1030
1011
|
};
|
|
1031
1012
|
}
|
|
1032
|
-
function toTSDownFormat(
|
|
1033
|
-
if (!
|
|
1013
|
+
function toTSDownFormat(format2) {
|
|
1014
|
+
if (!format2 || Array.isArray(format2) && format2.length === 0) {
|
|
1034
1015
|
return ["cjs", "es"];
|
|
1035
|
-
} else if (
|
|
1016
|
+
} else if (format2 === "esm") {
|
|
1036
1017
|
return "es";
|
|
1037
|
-
} else if (Array.isArray(
|
|
1038
|
-
return
|
|
1018
|
+
} else if (Array.isArray(format2)) {
|
|
1019
|
+
return format2.map((f) => f === "esm" ? "es" : f);
|
|
1039
1020
|
}
|
|
1040
|
-
return
|
|
1021
|
+
return format2;
|
|
1041
1022
|
}
|
|
1042
1023
|
|
|
1043
1024
|
// ../tsdown/src/build.ts
|
|
@@ -1571,7 +1552,16 @@ var _js = require('@nx/js');
|
|
|
1571
1552
|
var typesNodeVersion = "20.9.0";
|
|
1572
1553
|
var nxVersion = "^18.0.4";
|
|
1573
1554
|
var nodeVersion = "20.11.0";
|
|
1574
|
-
var pnpmVersion = "
|
|
1555
|
+
var pnpmVersion = "10.3.0";
|
|
1556
|
+
var npmVersion = "10.9.0";
|
|
1557
|
+
var yarnVersion = "4.6.0";
|
|
1558
|
+
var bunVersion = "1.2.0";
|
|
1559
|
+
var packageManagerVersions = {
|
|
1560
|
+
npm: npmVersion,
|
|
1561
|
+
yarn: yarnVersion,
|
|
1562
|
+
pnpm: pnpmVersion,
|
|
1563
|
+
bun: bunVersion
|
|
1564
|
+
};
|
|
1575
1565
|
|
|
1576
1566
|
// ../workspace-tools/src/base/typescript-library-generator.ts
|
|
1577
1567
|
async function typeScriptLibraryGeneratorFn(tree, options, config) {
|
|
@@ -1702,16 +1692,45 @@ async function typeScriptLibraryGeneratorFn(tree, options, config) {
|
|
|
1702
1692
|
});
|
|
1703
1693
|
}
|
|
1704
1694
|
if (tree.exists("package.json") && normalized.importPath) {
|
|
1705
|
-
_devkit.updateJson.call(void 0, tree, "package.json", (json) =>
|
|
1706
|
-
|
|
1707
|
-
|
|
1708
|
-
|
|
1709
|
-
|
|
1710
|
-
|
|
1711
|
-
|
|
1712
|
-
|
|
1695
|
+
_devkit.updateJson.call(void 0, tree, "package.json", (json) => {
|
|
1696
|
+
if (_optionalChain([config, 'optionalAccess', _148 => _148.packageManager]) === "yarn") {
|
|
1697
|
+
return {
|
|
1698
|
+
...json,
|
|
1699
|
+
resolutions: {
|
|
1700
|
+
..._optionalChain([json, 'optionalAccess', _149 => _149.resolutions]),
|
|
1701
|
+
[_nullishCoalesce(normalized.importPath, () => ( ""))]: "workspace:*"
|
|
1702
|
+
}
|
|
1703
|
+
};
|
|
1713
1704
|
}
|
|
1714
|
-
|
|
1705
|
+
if (_optionalChain([config, 'optionalAccess', _150 => _150.packageManager]) === "npm") {
|
|
1706
|
+
return {
|
|
1707
|
+
...json,
|
|
1708
|
+
overrides: {
|
|
1709
|
+
..._optionalChain([json, 'optionalAccess', _151 => _151.overrides]),
|
|
1710
|
+
[_nullishCoalesce(normalized.importPath, () => ( ""))]: "workspace:*"
|
|
1711
|
+
}
|
|
1712
|
+
};
|
|
1713
|
+
}
|
|
1714
|
+
if (_optionalChain([config, 'optionalAccess', _152 => _152.packageManager]) === "bun") {
|
|
1715
|
+
return {
|
|
1716
|
+
...json,
|
|
1717
|
+
overrides: {
|
|
1718
|
+
..._optionalChain([json, 'optionalAccess', _153 => _153.overrides]),
|
|
1719
|
+
[_nullishCoalesce(normalized.importPath, () => ( ""))]: "workspace:*"
|
|
1720
|
+
}
|
|
1721
|
+
};
|
|
1722
|
+
}
|
|
1723
|
+
return {
|
|
1724
|
+
...json,
|
|
1725
|
+
pnpm: {
|
|
1726
|
+
..._optionalChain([json, 'optionalAccess', _154 => _154.pnpm]),
|
|
1727
|
+
overrides: {
|
|
1728
|
+
..._optionalChain([json, 'optionalAccess', _155 => _155.pnpm, 'optionalAccess', _156 => _156.overrides]),
|
|
1729
|
+
[_nullishCoalesce(normalized.importPath, () => ( ""))]: "workspace:*"
|
|
1730
|
+
}
|
|
1731
|
+
}
|
|
1732
|
+
};
|
|
1733
|
+
});
|
|
1715
1734
|
}
|
|
1716
1735
|
_js.addTsConfigPath.call(void 0, tree, normalized.importPath, [
|
|
1717
1736
|
_chunkAWKQRM2Hjs.joinPaths.call(void 0,
|
|
@@ -1725,10 +1744,10 @@ async function typeScriptLibraryGeneratorFn(tree, options, config) {
|
|
|
1725
1744
|
]);
|
|
1726
1745
|
if (tree.exists("package.json")) {
|
|
1727
1746
|
const packageJson = _devkit.readJson.call(void 0, tree, "package.json");
|
|
1728
|
-
if (_optionalChain([packageJson, 'optionalAccess',
|
|
1747
|
+
if (_optionalChain([packageJson, 'optionalAccess', _157 => _157.repository])) {
|
|
1729
1748
|
repository = packageJson.repository;
|
|
1730
1749
|
}
|
|
1731
|
-
if (_optionalChain([packageJson, 'optionalAccess',
|
|
1750
|
+
if (_optionalChain([packageJson, 'optionalAccess', _158 => _158.description])) {
|
|
1732
1751
|
description = packageJson.description;
|
|
1733
1752
|
}
|
|
1734
1753
|
}
|
|
@@ -1765,22 +1784,22 @@ function getOutputPath(options) {
|
|
|
1765
1784
|
function createProjectTsConfigJson(tree, options) {
|
|
1766
1785
|
const tsconfig = {
|
|
1767
1786
|
extends: options.rootProject ? void 0 : _js.getRelativePathToRootTsConfig.call(void 0, tree, options.projectRoot),
|
|
1768
|
-
..._nullishCoalesce(_optionalChain([options, 'optionalAccess',
|
|
1787
|
+
..._nullishCoalesce(_optionalChain([options, 'optionalAccess', _159 => _159.tsconfigOptions]), () => ( {})),
|
|
1769
1788
|
compilerOptions: {
|
|
1770
1789
|
...options.rootProject ? _js.tsConfigBaseOptions : {},
|
|
1771
1790
|
outDir: _chunkAWKQRM2Hjs.joinPaths.call(void 0, _devkit.offsetFromRoot.call(void 0, options.projectRoot), "dist/out-tsc"),
|
|
1772
1791
|
noEmit: true,
|
|
1773
|
-
..._nullishCoalesce(_optionalChain([options, 'optionalAccess',
|
|
1792
|
+
..._nullishCoalesce(_optionalChain([options, 'optionalAccess', _160 => _160.tsconfigOptions, 'optionalAccess', _161 => _161.compilerOptions]), () => ( {}))
|
|
1774
1793
|
},
|
|
1775
|
-
files: [..._nullishCoalesce(_optionalChain([options, 'optionalAccess',
|
|
1794
|
+
files: [..._nullishCoalesce(_optionalChain([options, 'optionalAccess', _162 => _162.tsconfigOptions, 'optionalAccess', _163 => _163.files]), () => ( []))],
|
|
1776
1795
|
include: [
|
|
1777
|
-
..._nullishCoalesce(_optionalChain([options, 'optionalAccess',
|
|
1796
|
+
..._nullishCoalesce(_optionalChain([options, 'optionalAccess', _164 => _164.tsconfigOptions, 'optionalAccess', _165 => _165.include]), () => ( [])),
|
|
1778
1797
|
"src/**/*.ts",
|
|
1779
1798
|
"src/**/*.js",
|
|
1780
1799
|
"bin/**/*"
|
|
1781
1800
|
],
|
|
1782
1801
|
exclude: [
|
|
1783
|
-
..._nullishCoalesce(_optionalChain([options, 'optionalAccess',
|
|
1802
|
+
..._nullishCoalesce(_optionalChain([options, 'optionalAccess', _166 => _166.tsconfigOptions, 'optionalAccess', _167 => _167.exclude]), () => ( [])),
|
|
1784
1803
|
"jest.config.ts",
|
|
1785
1804
|
"src/**/*.spec.ts",
|
|
1786
1805
|
"src/**/*.test.ts"
|
|
@@ -1790,8 +1809,8 @@ function createProjectTsConfigJson(tree, options) {
|
|
|
1790
1809
|
}
|
|
1791
1810
|
async function normalizeOptions(tree, options, config) {
|
|
1792
1811
|
let importPath = options.importPath;
|
|
1793
|
-
if (!importPath && _optionalChain([config, 'optionalAccess',
|
|
1794
|
-
importPath = `@${_optionalChain([config, 'optionalAccess',
|
|
1812
|
+
if (!importPath && _optionalChain([config, 'optionalAccess', _168 => _168.namespace])) {
|
|
1813
|
+
importPath = `@${_optionalChain([config, 'optionalAccess', _169 => _169.namespace])}/${options.name}`;
|
|
1795
1814
|
}
|
|
1796
1815
|
if (options.publishable) {
|
|
1797
1816
|
if (!importPath) {
|
|
@@ -1956,7 +1975,7 @@ async function configSchemaGeneratorFn(tree, options, config) {
|
|
|
1956
1975
|
);
|
|
1957
1976
|
}
|
|
1958
1977
|
const outputPath = options.outputFile.replaceAll("{workspaceRoot}", "").replaceAll(
|
|
1959
|
-
_nullishCoalesce(_optionalChain([config, 'optionalAccess',
|
|
1978
|
+
_nullishCoalesce(_optionalChain([config, 'optionalAccess', _170 => _170.workspaceRoot]), () => ( _chunkYRUROEEPjs.findWorkspaceRoot.call(void 0, ))),
|
|
1960
1979
|
options.outputFile.startsWith("./") ? "" : "./"
|
|
1961
1980
|
);
|
|
1962
1981
|
_chunkAWKQRM2Hjs.writeTrace.call(void 0,
|
|
@@ -2122,8 +2141,53 @@ var generator_default4 = withRunGenerator(
|
|
|
2122
2141
|
|
|
2123
2142
|
|
|
2124
2143
|
|
|
2144
|
+
|
|
2145
|
+
|
|
2146
|
+
// ../workspace-tools/src/utils/lock-file.ts
|
|
2147
|
+
|
|
2148
|
+
|
|
2149
|
+
|
|
2150
|
+
|
|
2151
|
+
|
|
2152
|
+
|
|
2153
|
+
|
|
2154
|
+
|
|
2155
|
+
|
|
2156
|
+
|
|
2157
|
+
var _npmparser = require('nx/src/plugins/js/lock-file/npm-parser');
|
|
2158
|
+
|
|
2159
|
+
|
|
2160
|
+
|
|
2161
|
+
var _pnpmparser = require('nx/src/plugins/js/lock-file/pnpm-parser');
|
|
2162
|
+
|
|
2163
|
+
|
|
2164
|
+
|
|
2165
|
+
var _yarnparser = require('nx/src/plugins/js/lock-file/yarn-parser');
|
|
2166
|
+
var YARN_LOCK_FILE = "yarn.lock";
|
|
2167
|
+
var NPM_LOCK_FILE = "package-lock.json";
|
|
2168
|
+
var PNPM_LOCK_FILE = "pnpm-lock.yaml";
|
|
2169
|
+
var BUN_LOCK_FILE = "bun.lock";
|
|
2170
|
+
var YARN_LOCK_PATH = _path.join.call(void 0, _devkit.workspaceRoot, YARN_LOCK_FILE);
|
|
2171
|
+
var NPM_LOCK_PATH = _path.join.call(void 0, _devkit.workspaceRoot, NPM_LOCK_FILE);
|
|
2172
|
+
var PNPM_LOCK_PATH = _path.join.call(void 0, _devkit.workspaceRoot, PNPM_LOCK_FILE);
|
|
2173
|
+
var BUN_LOCK_PATH = _path.join.call(void 0, _devkit.workspaceRoot, BUN_LOCK_FILE);
|
|
2174
|
+
var LOCK_FILE_BY_PACKAGE_MANAGER = {
|
|
2175
|
+
npm: "package-lock.json",
|
|
2176
|
+
yarn: "yarn.lock",
|
|
2177
|
+
pnpm: "pnpm-lock.yaml",
|
|
2178
|
+
bun: "bun.lock"
|
|
2179
|
+
};
|
|
2180
|
+
function getLockFileName(packageManager) {
|
|
2181
|
+
return LOCK_FILE_BY_PACKAGE_MANAGER[packageManager];
|
|
2182
|
+
}
|
|
2183
|
+
|
|
2184
|
+
// ../workspace-tools/src/generators/preset/generator.ts
|
|
2125
2185
|
async function presetGeneratorFn(tree, options) {
|
|
2126
2186
|
const projectRoot = ".";
|
|
2187
|
+
const packageManager = _nullishCoalesce(options.packageManager, () => ( "pnpm"));
|
|
2188
|
+
const packageManagerVersion = packageManagerVersions[packageManager];
|
|
2189
|
+
const pmc = _devkit.getPackageManagerCommand.call(void 0, packageManager);
|
|
2190
|
+
const lockFileName = getLockFileName(packageManager);
|
|
2127
2191
|
options.description ??= `\u26A1The ${options.namespace ? options.namespace : options.name} monorepo contains utility applications, tools, and various libraries to create modern and scalable web applications.`;
|
|
2128
2192
|
options.namespace ??= options.organization;
|
|
2129
2193
|
_devkit.addProjectConfiguration.call(void 0, tree, `@${options.namespace}/${options.name}`, {
|
|
@@ -2191,11 +2255,6 @@ async function presetGeneratorFn(tree, options) {
|
|
|
2191
2255
|
type: "github",
|
|
2192
2256
|
url: `${options.repositoryUrl}.git`
|
|
2193
2257
|
};
|
|
2194
|
-
json.packageManager ??= "pnpm@10.3.0";
|
|
2195
|
-
json.engines ??= {
|
|
2196
|
-
node: ">=20.11.0",
|
|
2197
|
-
pnpm: ">=10.3.0"
|
|
2198
|
-
};
|
|
2199
2258
|
json.prettier = "@storm-software/prettier/config.json";
|
|
2200
2259
|
json.nx ??= {
|
|
2201
2260
|
includedScripts: [
|
|
@@ -2212,14 +2271,14 @@ async function presetGeneratorFn(tree, options) {
|
|
|
2212
2271
|
"release"
|
|
2213
2272
|
]
|
|
2214
2273
|
};
|
|
2215
|
-
json.scripts.adr = "
|
|
2216
|
-
json.scripts["adr-preview"] = "
|
|
2217
|
-
json.scripts.prepare =
|
|
2218
|
-
json.scripts.preinstall =
|
|
2219
|
-
json.scripts["install-csb"] = "corepack enable &&
|
|
2274
|
+
json.scripts.adr = pmc.run("log4brains", "adr new");
|
|
2275
|
+
json.scripts["adr-preview"] = pmc.run("log4brains", "preview");
|
|
2276
|
+
json.scripts.prepare = `${pmc.addDev} lefthook && ${packageManager} lefthook install`;
|
|
2277
|
+
json.scripts.preinstall = `npx -y only-allow ${packageManager}`;
|
|
2278
|
+
json.scripts["install-csb"] = packageManager === "bun" ? "bun install" : `corepack enable && ${pmc.install}`;
|
|
2220
2279
|
json.scripts.clean = "rimraf dist && rimraf --glob packages/**/dist && rimraf --glob tools/**/dist && rimraf --glob docs/**/dist && rimraf --glob apps/**/dist && rimraf --glob libs/**/dist";
|
|
2221
|
-
json.scripts.nuke =
|
|
2222
|
-
json.scripts.prebuild =
|
|
2280
|
+
json.scripts.nuke = `nx clear-cache && rimraf .nx/cache && rimraf .nx/workspace-data && ${packageManager} clean && rimraf ${lockFileName} && rimraf --glob packages/**/node_modules && rimraf --glob tools/**/node_modules && rimraf node_modules`;
|
|
2281
|
+
json.scripts.prebuild = `${packageManager} clean`;
|
|
2223
2282
|
json.scripts.build = "nx affected -t build --parallel=5";
|
|
2224
2283
|
json.scripts["build-all"] = "nx run-many -t build --all --parallel=5";
|
|
2225
2284
|
json.scripts["build-prod"] = "nx run-many -t build --all --prod --parallel=5";
|
|
@@ -2234,45 +2293,53 @@ async function presetGeneratorFn(tree, options) {
|
|
|
2234
2293
|
}
|
|
2235
2294
|
json.scripts.nx = "nx";
|
|
2236
2295
|
json.scripts.graph = "nx graph";
|
|
2237
|
-
json.scripts.lint = "pnpm storm-lint all --skip-cspell --skip-alex";
|
|
2238
2296
|
if (options.includeApps) {
|
|
2239
2297
|
json.scripts.start = "nx serve";
|
|
2240
|
-
json.scripts.storybook = "
|
|
2298
|
+
json.scripts.storybook = pmc.run("storybook", "dev -p 6006");
|
|
2241
2299
|
}
|
|
2242
2300
|
json.scripts.help = "nx help";
|
|
2243
2301
|
json.scripts["dep-graph"] = "nx dep-graph";
|
|
2244
2302
|
json.scripts["local-registry"] = `nx local-registry @${options.namespace}/${options.name}`;
|
|
2245
2303
|
json.scripts.e2e = "nx e2e";
|
|
2246
2304
|
if (options.includeApps) {
|
|
2247
|
-
json.scripts.test =
|
|
2248
|
-
json.scripts["test-storybook"] =
|
|
2305
|
+
json.scripts.test = `nx test && ${packageManager} test-storybook`;
|
|
2306
|
+
json.scripts["test-storybook"] = `${packageManager} test-storybook`;
|
|
2249
2307
|
} else {
|
|
2250
2308
|
json.scripts.test = "nx test";
|
|
2251
2309
|
}
|
|
2252
|
-
json.scripts.
|
|
2253
|
-
json.scripts
|
|
2254
|
-
|
|
2255
|
-
|
|
2310
|
+
json.scripts.commit = pmc.run("storm-git", "commit");
|
|
2311
|
+
json.scripts["api-extractor"] = pmc.run(
|
|
2312
|
+
"storm-docs",
|
|
2313
|
+
'api-extractor --outputPath="docs/api-reference" --clean'
|
|
2314
|
+
);
|
|
2315
|
+
json.scripts.release = pmc.run("storm-git", "release");
|
|
2256
2316
|
json.scripts.format = "nx format:write";
|
|
2257
|
-
json.scripts["format-sherif"] =
|
|
2258
|
-
json.scripts["format-toml"] =
|
|
2259
|
-
json.scripts["format-readme"] =
|
|
2260
|
-
|
|
2261
|
-
|
|
2262
|
-
|
|
2263
|
-
json.scripts["
|
|
2264
|
-
json.scripts
|
|
2265
|
-
json.
|
|
2317
|
+
json.scripts["format-sherif"] = `${pmc.exec} sherif -f -i typescript -i react -i react-dom`;
|
|
2318
|
+
json.scripts["format-toml"] = `${pmc.exec} taplo format --config="./node_modules/@storm-software/linting-tools/taplo/config.toml" --cache-path="./node_modules/.cache/storm/taplo"`;
|
|
2319
|
+
json.scripts["format-readme"] = pmc.run(
|
|
2320
|
+
"storm-git",
|
|
2321
|
+
'readme --templates="tools/readme-templates"'
|
|
2322
|
+
);
|
|
2323
|
+
json.scripts["format-prettier"] = `${pmc.exec} prettier --write --ignore-unknown --no-error-on-unmatched-pattern --cache && git update-index`;
|
|
2324
|
+
json.scripts.lint = pmc.run("storm-lint", "all --skip-cspell");
|
|
2325
|
+
json.scripts["lint-knip"] = `${pmc.exec} knip`;
|
|
2326
|
+
json.scripts["lint-sherif"] = `${pmc.exec} sherif -i typescript -i react -i react-dom`;
|
|
2327
|
+
json.scripts["lint-ls"] = `${pmc.exec} ls-lint --config="./node_modules/@storm-software/linting-tools/ls-lint/ls-lint.yml"`;
|
|
2328
|
+
json.packageManager ??= `${packageManager}@${packageManagerVersion}`;
|
|
2266
2329
|
json.engines = {
|
|
2267
2330
|
node: `>=${nodeVersion}`,
|
|
2268
|
-
|
|
2331
|
+
[packageManager]: `>=${packageManagerVersion}`
|
|
2269
2332
|
};
|
|
2270
2333
|
return json;
|
|
2271
2334
|
});
|
|
2272
2335
|
_devkit.generateFiles.call(void 0, tree, path2.join(__dirname, "files"), projectRoot, {
|
|
2273
2336
|
...options,
|
|
2337
|
+
packageManager,
|
|
2338
|
+
packageManagerVersion,
|
|
2274
2339
|
pnpmVersion,
|
|
2275
|
-
nodeVersion
|
|
2340
|
+
nodeVersion,
|
|
2341
|
+
lockFileName,
|
|
2342
|
+
exec: pmc.exec
|
|
2276
2343
|
});
|
|
2277
2344
|
await _devkit.formatFiles.call(void 0, tree);
|
|
2278
2345
|
let dependencies = {
|
|
@@ -2728,33 +2795,6 @@ var _release = require('nx/release');
|
|
|
2728
2795
|
// ../workspace-tools/src/utils/get-project-configurations.ts
|
|
2729
2796
|
var _retrieveworkspacefiles = require('nx/src/project-graph/utils/retrieve-workspace-files');
|
|
2730
2797
|
|
|
2731
|
-
// ../workspace-tools/src/utils/lock-file.ts
|
|
2732
|
-
|
|
2733
|
-
|
|
2734
|
-
|
|
2735
|
-
|
|
2736
|
-
|
|
2737
|
-
|
|
2738
|
-
|
|
2739
|
-
|
|
2740
|
-
|
|
2741
|
-
|
|
2742
|
-
var _npmparser = require('nx/src/plugins/js/lock-file/npm-parser');
|
|
2743
|
-
|
|
2744
|
-
|
|
2745
|
-
|
|
2746
|
-
var _pnpmparser = require('nx/src/plugins/js/lock-file/pnpm-parser');
|
|
2747
|
-
|
|
2748
|
-
|
|
2749
|
-
|
|
2750
|
-
var _yarnparser = require('nx/src/plugins/js/lock-file/yarn-parser');
|
|
2751
|
-
var YARN_LOCK_FILE = "yarn.lock";
|
|
2752
|
-
var NPM_LOCK_FILE = "package-lock.json";
|
|
2753
|
-
var PNPM_LOCK_FILE = "pnpm-lock.yaml";
|
|
2754
|
-
var YARN_LOCK_PATH = _path.join.call(void 0, _devkit.workspaceRoot, YARN_LOCK_FILE);
|
|
2755
|
-
var NPM_LOCK_PATH = _path.join.call(void 0, _devkit.workspaceRoot, NPM_LOCK_FILE);
|
|
2756
|
-
var PNPM_LOCK_PATH = _path.join.call(void 0, _devkit.workspaceRoot, PNPM_LOCK_FILE);
|
|
2757
|
-
|
|
2758
2798
|
// ../workspace-tools/config/recommended.json
|
|
2759
2799
|
var recommended_default = {
|
|
2760
2800
|
$schema: "https://cdn.jsdelivr.net/npm/nx/schemas/nx-schema.json",
|
|
@@ -2763,15 +2803,12 @@ var recommended_default = {
|
|
|
2763
2803
|
allProjectFiles: ["sharedGlobals", "{projectRoot}/**/*"],
|
|
2764
2804
|
default: ["sharedGlobals", "{projectRoot}/**/*"],
|
|
2765
2805
|
sharedGlobals: [
|
|
2766
|
-
"{workspaceRoot}/.github/workflows/*.yml",
|
|
2767
|
-
"{workspaceRoot}/assets/**/*",
|
|
2768
2806
|
"{workspaceRoot}/tsconfig.json",
|
|
2769
|
-
"{workspaceRoot}/tsconfig
|
|
2807
|
+
"{workspaceRoot}/tsconfig.*.json",
|
|
2770
2808
|
"{workspaceRoot}/.npm@(rc|ignore)",
|
|
2771
2809
|
"{workspaceRoot}/package.json",
|
|
2772
2810
|
"{workspaceRoot}/{pnpm-workspace,pnpm-lock,package-lock,yarn-lock}.@(yaml|yml)",
|
|
2773
|
-
"{workspaceRoot}/bun.
|
|
2774
|
-
"{workspaceRoot}/LICENSE",
|
|
2811
|
+
"{workspaceRoot}/bun.lock{,b}",
|
|
2775
2812
|
"{workspaceRoot}/.git@(attributes|ignore)",
|
|
2776
2813
|
"{workspaceRoot}/{nx.json,.nxignore}",
|
|
2777
2814
|
"{workspaceRoot}/storm-workspace{,.*}.@(json|yaml|toml)",
|
|
@@ -2779,7 +2816,6 @@ var recommended_default = {
|
|
|
2779
2816
|
"{workspaceRoot}/storm-workspace.config.[jt]s",
|
|
2780
2817
|
"{workspaceRoot}/.storm-workspace/config{,.*}.[jt]s",
|
|
2781
2818
|
"{workspaceRoot}/devenv.@(lock|nix|yaml)",
|
|
2782
|
-
"{workspaceRoot}/{flake,shell,devShell}.nix",
|
|
2783
2819
|
"{workspaceRoot}/.envrc",
|
|
2784
2820
|
"{workspaceRoot}/.env{,.local,.*}"
|
|
2785
2821
|
],
|
|
@@ -2886,14 +2922,12 @@ var recommended_default = {
|
|
|
2886
2922
|
"{workspaceRoot}/Cargo.lock",
|
|
2887
2923
|
"{workspaceRoot}/.cargo/config.toml",
|
|
2888
2924
|
"{workspaceRoot}/rust-toolchain",
|
|
2889
|
-
"{workspaceRoot}/rustfmt.toml",
|
|
2890
|
-
"{workspaceRoot}/deny.toml",
|
|
2891
2925
|
"{projectRoot}/Cargo.toml",
|
|
2892
2926
|
"{projectRoot}/.cargo/config.toml",
|
|
2893
2927
|
{
|
|
2894
2928
|
runtime: "node -p '`${process.platform}_${process.arch}`'"
|
|
2895
2929
|
},
|
|
2896
|
-
"{projectRoot}/
|
|
2930
|
+
"{projectRoot}/project.json",
|
|
2897
2931
|
"{projectRoot}/.env{,.local}",
|
|
2898
2932
|
"{projectRoot}/**/*.rs",
|
|
2899
2933
|
"{projectRoot}/**/*.@(proto|acid|acidic|prisma)",
|
|
@@ -2912,14 +2946,22 @@ var recommended_default = {
|
|
|
2912
2946
|
"{projectRoot}/package.json",
|
|
2913
2947
|
"{projectRoot}/tsconfig.json",
|
|
2914
2948
|
"{projectRoot}/tsconfig.*.json",
|
|
2915
|
-
"{projectRoot}/
|
|
2949
|
+
"{projectRoot}/project.json",
|
|
2916
2950
|
"{projectRoot}/.env{,.*}",
|
|
2917
|
-
"{projectRoot}/docs/**/*",
|
|
2918
|
-
"{projectRoot}/**/*.stories.@(js|jsx|ts|tsx|mdx)",
|
|
2951
|
+
"!{projectRoot}/docs/**/*",
|
|
2952
|
+
"!{projectRoot}/**/*.stories.@(js|jsx|ts|tsx|mdx)",
|
|
2919
2953
|
"{projectRoot}/**/*.@(proto|acid|acidic|prisma)",
|
|
2920
2954
|
"{projectRoot}/src/**/*.@(cts|mts|ts|tsx|graphql|gql|js|cjs|mjs|jsx|json|jsonc|yaml|yml|toml|md|mdx)",
|
|
2921
2955
|
"{projectRoot}/{build,tsup,tsdown,vite,contentlayer,powerlines,shell-shock,earthquake}.*.[jt]s?(x)",
|
|
2922
2956
|
"{projectRoot}/{bin,tools,helpers,scripts}/**/*"
|
|
2957
|
+
],
|
|
2958
|
+
ci: [
|
|
2959
|
+
"sharedGlobals",
|
|
2960
|
+
"{workspaceRoot}/.github/workflows/*.yml",
|
|
2961
|
+
"{workspaceRoot}/assets/**/*",
|
|
2962
|
+
"{workspaceRoot}/devenv.@(lock|nix|yaml)",
|
|
2963
|
+
"{workspaceRoot}/.devenv{,.flake.nix}",
|
|
2964
|
+
"{workspaceRoot}/.direnv"
|
|
2923
2965
|
]
|
|
2924
2966
|
},
|
|
2925
2967
|
targetDefaults: {
|
|
@@ -2930,8 +2972,8 @@ var recommended_default = {
|
|
|
2930
2972
|
executor: "nx:run-commands",
|
|
2931
2973
|
options: {
|
|
2932
2974
|
commands: [
|
|
2933
|
-
"
|
|
2934
|
-
"
|
|
2975
|
+
"rimraf --glob {projectRoot}/dist",
|
|
2976
|
+
"rimraf dist/{projectRoot}"
|
|
2935
2977
|
]
|
|
2936
2978
|
}
|
|
2937
2979
|
},
|
|
@@ -2951,7 +2993,7 @@ var recommended_default = {
|
|
|
2951
2993
|
version: {
|
|
2952
2994
|
currentVersionResolver: "git-tag",
|
|
2953
2995
|
specifierSource: "conventional-commits",
|
|
2954
|
-
groupPreVersionCommand: "
|
|
2996
|
+
groupPreVersionCommand: "build",
|
|
2955
2997
|
manifestRootsToUpdate: [
|
|
2956
2998
|
"{projectRoot}",
|
|
2957
2999
|
{
|
package/dist/executors.js
CHANGED
|
@@ -3,7 +3,7 @@ require('./chunk-FLA2SYPV.js');
|
|
|
3
3
|
require('./chunk-KUGEZPUO.js');
|
|
4
4
|
require('./chunk-CLCKX6UN.js');
|
|
5
5
|
require('./chunk-HNDXHX7M.js');
|
|
6
|
-
require('./chunk-
|
|
6
|
+
require('./chunk-XKZTXB5T.js');
|
|
7
7
|
require('./chunk-NCVDTA5M.js');
|
|
8
8
|
require('./chunk-YRUROEEP.js');
|
|
9
9
|
require('./chunk-FBLD25X4.js');
|
package/dist/executors.mjs
CHANGED
|
@@ -3,7 +3,7 @@ import "./chunk-WTWLKDV7.mjs";
|
|
|
3
3
|
import "./chunk-SWYYMID7.mjs";
|
|
4
4
|
import "./chunk-BY7MA3SM.mjs";
|
|
5
5
|
import "./chunk-BTKJRCZQ.mjs";
|
|
6
|
-
import "./chunk-
|
|
6
|
+
import "./chunk-GYIUU2G4.mjs";
|
|
7
7
|
import "./chunk-ZXLMDNFQ.mjs";
|
|
8
8
|
import "./chunk-BJQFVPGK.mjs";
|
|
9
9
|
import "./chunk-CSTZEHUP.mjs";
|
package/dist/generators.js
CHANGED
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
|
|
4
4
|
|
|
5
|
-
var
|
|
5
|
+
var _chunkO6QQDVZ5js = require('./chunk-O6QQDVZ5.js');
|
|
6
6
|
|
|
7
7
|
|
|
8
8
|
|
|
9
|
-
var
|
|
9
|
+
var _chunkUGIZ5QUSjs = require('./chunk-UGIZ5QUS.js');
|
|
10
10
|
require('./chunk-YRUROEEP.js');
|
|
11
11
|
require('./chunk-AWKQRM2H.js');
|
|
12
12
|
require('./chunk-MCKGQKYU.js');
|
|
@@ -15,4 +15,4 @@ require('./chunk-MCKGQKYU.js');
|
|
|
15
15
|
|
|
16
16
|
|
|
17
17
|
|
|
18
|
-
exports.applicationGenerator =
|
|
18
|
+
exports.applicationGenerator = _chunkO6QQDVZ5js.applicationGenerator; exports.applicationSchematic = _chunkO6QQDVZ5js.applicationSchematic; exports.initGenerator = _chunkUGIZ5QUSjs.initGenerator; exports.initSchematic = _chunkUGIZ5QUSjs.initSchematic;
|
package/dist/generators.mjs
CHANGED
|
@@ -2,11 +2,11 @@ import "./chunk-3J7KBHMJ.mjs";
|
|
|
2
2
|
import {
|
|
3
3
|
applicationGenerator,
|
|
4
4
|
applicationSchematic
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-KZQP6DGG.mjs";
|
|
6
6
|
import {
|
|
7
7
|
initGenerator,
|
|
8
8
|
initSchematic
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-MCCHKUCS.mjs";
|
|
10
10
|
import "./chunk-BJQFVPGK.mjs";
|
|
11
11
|
import "./chunk-K4H5ZMYA.mjs";
|
|
12
12
|
import "./chunk-WPIQWFHD.mjs";
|
package/dist/index.js
CHANGED
|
@@ -4,11 +4,11 @@ require('./chunk-DHBG5ASJ.js');
|
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
7
|
-
var
|
|
7
|
+
var _chunkO6QQDVZ5js = require('./chunk-O6QQDVZ5.js');
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
11
|
-
var
|
|
11
|
+
var _chunkUGIZ5QUSjs = require('./chunk-UGIZ5QUS.js');
|
|
12
12
|
|
|
13
13
|
|
|
14
14
|
|
|
@@ -22,7 +22,7 @@ require('./chunk-CVGPWUNP.js');
|
|
|
22
22
|
|
|
23
23
|
var _chunkCLCKX6UNjs = require('./chunk-CLCKX6UN.js');
|
|
24
24
|
require('./chunk-HNDXHX7M.js');
|
|
25
|
-
require('./chunk-
|
|
25
|
+
require('./chunk-XKZTXB5T.js');
|
|
26
26
|
require('./chunk-NCVDTA5M.js');
|
|
27
27
|
require('./chunk-YRUROEEP.js');
|
|
28
28
|
require('./chunk-FBLD25X4.js');
|
|
@@ -39,4 +39,4 @@ require('./chunk-MCKGQKYU.js');
|
|
|
39
39
|
|
|
40
40
|
|
|
41
41
|
|
|
42
|
-
exports.applicationGenerator =
|
|
42
|
+
exports.applicationGenerator = _chunkO6QQDVZ5js.applicationGenerator; exports.applicationSchematic = _chunkO6QQDVZ5js.applicationSchematic; exports.createNodesV2 = _chunkVJLWHQ5Bjs.createNodesV2; exports.getEncoding = _chunkCLCKX6UNjs.getEncoding; exports.getInternalDependencies = _chunkCLCKX6UNjs.getInternalDependencies; exports.initGenerator = _chunkUGIZ5QUSjs.initGenerator; exports.initSchematic = _chunkUGIZ5QUSjs.initSchematic; exports.isTextFile = _chunkCLCKX6UNjs.isTextFile; exports.name = _chunkVJLWHQ5Bjs.name; exports.uploadFile = _chunkCLCKX6UNjs.uploadFile;
|