@storm-software/workspace-tools 1.295.40 → 1.295.42
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-R77GVEUP.mjs → chunk-JTFVPJ2Y.mjs} +1 -1
- package/dist/{chunk-PSVEAG4P.js → chunk-PR737KX2.js} +8 -8
- package/dist/{chunk-IESO3CZY.mjs → chunk-RSZQYKKW.mjs} +1 -1
- package/dist/{chunk-DQWLUIY3.js → chunk-VXH74KT7.js} +7 -7
- package/dist/executors.js +5 -5
- package/dist/executors.mjs +4 -4
- package/dist/index.js +19 -19
- package/dist/index.mjs +26 -26
- package/dist/src/executors/esbuild/executor.js +3 -3
- package/dist/src/executors/esbuild/executor.mjs +2 -2
- package/dist/src/executors/tsdown/executor.js +3 -3
- package/dist/src/executors/tsdown/executor.mjs +2 -2
- package/dist/src/utils/index.js +10 -10
- package/dist/src/utils/index.mjs +16 -16
- package/package.json +9 -9
- package/dist/chunk-2SRFINBN.mjs +0 -32
- package/dist/chunk-4RQ25E7U.js +0 -32
- package/dist/chunk-FJJD4XQQ.js +0 -41
- package/dist/chunk-FYWTWKA5.mjs +0 -116
- package/dist/chunk-GVNAKGP4.mjs +0 -31
- package/dist/chunk-H4MADHCO.js +0 -32
- package/dist/chunk-LWYN4MTV.js +0 -79
- package/dist/chunk-MCQCIP4X.mjs +0 -548
- package/dist/chunk-NNQPSEZU.js +0 -31
- package/dist/chunk-NQHO4D7T.js +0 -250
- package/dist/chunk-OTKWSGS5.mjs +0 -32
- package/dist/chunk-OZQ7BMMQ.js +0 -93
- package/dist/chunk-P5KUQQTV.mjs +0 -93
- package/dist/chunk-QWOCJPHV.mjs +0 -82
- package/dist/chunk-QYWP6FSH.js +0 -548
- package/dist/chunk-RVMTVA24.mjs +0 -253
- package/dist/chunk-SGNQWNB4.js +0 -116
- package/dist/chunk-T7O5BE2A.mjs +0 -32
- package/dist/chunk-UTIKWDU3.mjs +0 -41
- package/dist/chunk-WLCY3GMY.js +0 -32
- /package/dist/{chunk-EDULOZPA.mjs → chunk-I4X5CIJM.mjs} +0 -0
- /package/dist/{chunk-NWFBYOJV.js → chunk-RB72JOT5.js} +0 -0
package/dist/src/utils/index.mjs
CHANGED
|
@@ -1,14 +1,4 @@
|
|
|
1
1
|
import "../../chunk-6YZ3OUJB.mjs";
|
|
2
|
-
import {
|
|
3
|
-
getTypiaTransform
|
|
4
|
-
} from "../../chunk-KR72GKIT.mjs";
|
|
5
|
-
import {
|
|
6
|
-
createCliOptions
|
|
7
|
-
} from "../../chunk-W2C5IGWW.mjs";
|
|
8
|
-
import {
|
|
9
|
-
getProjectConfiguration,
|
|
10
|
-
getProjectConfigurations
|
|
11
|
-
} from "../../chunk-AH7KAAQJ.mjs";
|
|
12
2
|
import {
|
|
13
3
|
LOCK_FILES,
|
|
14
4
|
NPM_LOCK_FILE,
|
|
@@ -34,9 +24,25 @@ import {
|
|
|
34
24
|
getProjectRoot,
|
|
35
25
|
getRoot
|
|
36
26
|
} from "../../chunk-FKPWMB63.mjs";
|
|
27
|
+
import {
|
|
28
|
+
getTypiaTransform
|
|
29
|
+
} from "../../chunk-KR72GKIT.mjs";
|
|
37
30
|
import {
|
|
38
31
|
applyWorkspaceExecutorTokens
|
|
39
32
|
} from "../../chunk-UBVTASOE.mjs";
|
|
33
|
+
import {
|
|
34
|
+
createCliOptions
|
|
35
|
+
} from "../../chunk-W2C5IGWW.mjs";
|
|
36
|
+
import {
|
|
37
|
+
getProjectConfiguration,
|
|
38
|
+
getProjectConfigurations
|
|
39
|
+
} from "../../chunk-AH7KAAQJ.mjs";
|
|
40
|
+
import {
|
|
41
|
+
PackageManagerTypes,
|
|
42
|
+
addPackageJsonGitHead,
|
|
43
|
+
getPackageInfo
|
|
44
|
+
} from "../../chunk-OVTQ7MFY.mjs";
|
|
45
|
+
import "../../chunk-GEN563U4.mjs";
|
|
40
46
|
import {
|
|
41
47
|
INVALID_CARGO_ARGS,
|
|
42
48
|
buildCargoCommand,
|
|
@@ -48,12 +54,6 @@ import {
|
|
|
48
54
|
isExternal,
|
|
49
55
|
runProcess
|
|
50
56
|
} from "../../chunk-ZTN2676G.mjs";
|
|
51
|
-
import {
|
|
52
|
-
PackageManagerTypes,
|
|
53
|
-
addPackageJsonGitHead,
|
|
54
|
-
getPackageInfo
|
|
55
|
-
} from "../../chunk-OVTQ7MFY.mjs";
|
|
56
|
-
import "../../chunk-GEN563U4.mjs";
|
|
57
57
|
import {
|
|
58
58
|
eslintVersion,
|
|
59
59
|
lintStagedVersion,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@storm-software/workspace-tools",
|
|
3
|
-
"version": "1.295.
|
|
3
|
+
"version": "1.295.42",
|
|
4
4
|
"description": "Tools for managing a Storm workspace, including various Nx generators and executors for common development tasks.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"monorepo",
|
|
@@ -228,13 +228,13 @@
|
|
|
228
228
|
"@size-limit/esbuild": "11.1.4",
|
|
229
229
|
"@size-limit/esbuild-why": "11.1.4",
|
|
230
230
|
"@size-limit/file": "11.1.4",
|
|
231
|
-
"@storm-software/config-tools": "^1.189.
|
|
232
|
-
"@storm-software/esbuild": "^0.53.
|
|
233
|
-
"@storm-software/npm-tools": "^0.6.
|
|
234
|
-
"@storm-software/pnpm-tools": "^0.6.
|
|
235
|
-
"@storm-software/prettier": "^0.59.
|
|
236
|
-
"@storm-software/tsdown": "^0.45.
|
|
237
|
-
"@storm-software/unbuild": "^0.57.
|
|
231
|
+
"@storm-software/config-tools": "^1.189.66",
|
|
232
|
+
"@storm-software/esbuild": "^0.53.148",
|
|
233
|
+
"@storm-software/npm-tools": "^0.6.104",
|
|
234
|
+
"@storm-software/pnpm-tools": "^0.6.151",
|
|
235
|
+
"@storm-software/prettier": "^0.59.40",
|
|
236
|
+
"@storm-software/tsdown": "^0.45.148",
|
|
237
|
+
"@storm-software/unbuild": "^0.57.148",
|
|
238
238
|
"fs-extra": "11.2.0",
|
|
239
239
|
"glob": "^11.1.0",
|
|
240
240
|
"jiti": "2.4.2",
|
|
@@ -272,5 +272,5 @@
|
|
|
272
272
|
"publishConfig": { "access": "public" },
|
|
273
273
|
"executors": "./executors.json",
|
|
274
274
|
"generators": "./generators.json",
|
|
275
|
-
"gitHead": "
|
|
275
|
+
"gitHead": "c42d6c0ae19c100006234c16e077e9a189ffcbec"
|
|
276
276
|
}
|
package/dist/chunk-2SRFINBN.mjs
DELETED
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
withRunExecutor
|
|
3
|
-
} from "./chunk-QOQ7ZZDR.mjs";
|
|
4
|
-
import {
|
|
5
|
-
buildCargoCommand,
|
|
6
|
-
cargoCommand
|
|
7
|
-
} from "./chunk-ZTN2676G.mjs";
|
|
8
|
-
|
|
9
|
-
// src/executors/cargo-clippy/executor.ts
|
|
10
|
-
async function cargoClippyExecutor(options, context) {
|
|
11
|
-
const command = buildCargoCommand("clippy", options, context);
|
|
12
|
-
return await cargoCommand(context.root, ...command);
|
|
13
|
-
}
|
|
14
|
-
var executor_default = withRunExecutor(
|
|
15
|
-
"Cargo - Clippy",
|
|
16
|
-
cargoClippyExecutor,
|
|
17
|
-
{
|
|
18
|
-
skipReadingConfig: false,
|
|
19
|
-
hooks: {
|
|
20
|
-
applyDefaultOptions: (options) => {
|
|
21
|
-
options.toolchain ??= "stable";
|
|
22
|
-
options.fix ??= false;
|
|
23
|
-
return options;
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
);
|
|
28
|
-
|
|
29
|
-
export {
|
|
30
|
-
cargoClippyExecutor,
|
|
31
|
-
executor_default
|
|
32
|
-
};
|
package/dist/chunk-4RQ25E7U.js
DELETED
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
|
-
|
|
3
|
-
var _chunkRO2CCHL3js = require('./chunk-RO2CCHL3.js');
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
var _chunkD2PV33E5js = require('./chunk-D2PV33E5.js');
|
|
8
|
-
|
|
9
|
-
// src/executors/cargo-format/executor.ts
|
|
10
|
-
async function cargoFormatExecutor(options, context) {
|
|
11
|
-
const command = _chunkD2PV33E5js.buildCargoCommand.call(void 0, "fmt", options, context);
|
|
12
|
-
return await _chunkD2PV33E5js.cargoCommand.call(void 0, context.root, ...command);
|
|
13
|
-
}
|
|
14
|
-
var executor_default = _chunkRO2CCHL3js.withRunExecutor.call(void 0,
|
|
15
|
-
"Cargo - Format",
|
|
16
|
-
cargoFormatExecutor,
|
|
17
|
-
{
|
|
18
|
-
skipReadingConfig: false,
|
|
19
|
-
hooks: {
|
|
20
|
-
applyDefaultOptions: (options) => {
|
|
21
|
-
options.outputPath ??= "dist/{projectRoot}/target";
|
|
22
|
-
options.toolchain ??= "stable";
|
|
23
|
-
return options;
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
);
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
exports.cargoFormatExecutor = cargoFormatExecutor; exports.executor_default = executor_default;
|
package/dist/chunk-FJJD4XQQ.js
DELETED
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
|
-
|
|
3
|
-
var _chunkRO2CCHL3js = require('./chunk-RO2CCHL3.js');
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
var _chunkD2PV33E5js = require('./chunk-D2PV33E5.js');
|
|
8
|
-
|
|
9
|
-
// src/executors/cargo-doc/executor.ts
|
|
10
|
-
async function cargoDocExecutor(options, context) {
|
|
11
|
-
const opts = { ...options };
|
|
12
|
-
opts["no-deps"] = opts.noDeps;
|
|
13
|
-
delete opts.noDeps;
|
|
14
|
-
const command = _chunkD2PV33E5js.buildCargoCommand.call(void 0, "doc", options, context);
|
|
15
|
-
return await _chunkD2PV33E5js.cargoCommand.call(void 0, context.root, ...command);
|
|
16
|
-
}
|
|
17
|
-
var executor_default = _chunkRO2CCHL3js.withRunExecutor.call(void 0,
|
|
18
|
-
"Cargo - Doc",
|
|
19
|
-
cargoDocExecutor,
|
|
20
|
-
{
|
|
21
|
-
skipReadingConfig: false,
|
|
22
|
-
hooks: {
|
|
23
|
-
applyDefaultOptions: (options) => {
|
|
24
|
-
options.outputPath ??= "dist/{projectRoot}/docs";
|
|
25
|
-
options.toolchain ??= "stable";
|
|
26
|
-
options.release ??= options.profile ? false : true;
|
|
27
|
-
options.allFeatures ??= true;
|
|
28
|
-
options.lib ??= true;
|
|
29
|
-
options.bins ??= true;
|
|
30
|
-
options.examples ??= true;
|
|
31
|
-
options.noDeps ??= false;
|
|
32
|
-
return options;
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
);
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
exports.cargoDocExecutor = cargoDocExecutor; exports.executor_default = executor_default;
|
package/dist/chunk-FYWTWKA5.mjs
DELETED
|
@@ -1,116 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
withRunExecutor
|
|
3
|
-
} from "./chunk-QOQ7ZZDR.mjs";
|
|
4
|
-
import {
|
|
5
|
-
cargoMetadata
|
|
6
|
-
} from "./chunk-ZTN2676G.mjs";
|
|
7
|
-
import {
|
|
8
|
-
correctPaths,
|
|
9
|
-
isAbsolute,
|
|
10
|
-
joinPaths,
|
|
11
|
-
relative
|
|
12
|
-
} from "./chunk-TBW5MCN6.mjs";
|
|
13
|
-
|
|
14
|
-
// src/executors/napi/executor.ts
|
|
15
|
-
import { createJiti } from "jiti";
|
|
16
|
-
import { fileExists } from "nx/src/utils/fileutils";
|
|
17
|
-
async function napiExecutor(options, context, config) {
|
|
18
|
-
const jiti = createJiti(config.workspaceRoot, {
|
|
19
|
-
fsCache: config.skipCache ? false : joinPaths(
|
|
20
|
-
config.workspaceRoot,
|
|
21
|
-
config.directories.cache || "node_modules/.cache/storm",
|
|
22
|
-
"jiti"
|
|
23
|
-
),
|
|
24
|
-
interopDefault: true
|
|
25
|
-
});
|
|
26
|
-
const { NapiCli } = await jiti.import(
|
|
27
|
-
jiti.esmResolve("@napi-rs/cli")
|
|
28
|
-
);
|
|
29
|
-
if (!context.projectGraph?.nodes[context.projectName ?? ""]) {
|
|
30
|
-
throw new Error(
|
|
31
|
-
"The Napi Build process failed because the project could not be found in the project graph. Please run this command from a workspace root directory."
|
|
32
|
-
);
|
|
33
|
-
}
|
|
34
|
-
const projectRoot = context.projectGraph?.nodes[context.projectName ?? ""].data.root;
|
|
35
|
-
const packageJson = joinPaths(projectRoot ?? ".", "package.json");
|
|
36
|
-
if (!fileExists(packageJson)) {
|
|
37
|
-
throw new Error(`Could not find package.json at ${packageJson}`);
|
|
38
|
-
}
|
|
39
|
-
const napi = new NapiCli();
|
|
40
|
-
const normalizedOptions = { ...options };
|
|
41
|
-
const metadata = cargoMetadata();
|
|
42
|
-
normalizedOptions.targetDir = options.targetDir || metadata?.target_directory || joinPaths(config.workspaceRoot, "dist", "target");
|
|
43
|
-
normalizedOptions.outputDir = options.outputPath;
|
|
44
|
-
normalizedOptions.packageJsonPath = options.packageJsonPath || packageJson;
|
|
45
|
-
if (options.cwd) {
|
|
46
|
-
normalizedOptions.cwd = correctPaths(options.cwd);
|
|
47
|
-
} else {
|
|
48
|
-
normalizedOptions.cwd = correctPaths(projectRoot);
|
|
49
|
-
const absoluteProjectRoot = joinPaths(
|
|
50
|
-
config.workspaceRoot,
|
|
51
|
-
projectRoot || "."
|
|
52
|
-
);
|
|
53
|
-
if (normalizedOptions.outputDir) {
|
|
54
|
-
normalizedOptions.outputDir = relative(
|
|
55
|
-
absoluteProjectRoot,
|
|
56
|
-
correctPaths(
|
|
57
|
-
isAbsolute(normalizedOptions.outputDir) ? normalizedOptions.outputDir : joinPaths(config.workspaceRoot, normalizedOptions.outputDir)
|
|
58
|
-
)
|
|
59
|
-
);
|
|
60
|
-
}
|
|
61
|
-
if (normalizedOptions.packageJsonPath) {
|
|
62
|
-
normalizedOptions.packageJsonPath = relative(
|
|
63
|
-
absoluteProjectRoot,
|
|
64
|
-
correctPaths(
|
|
65
|
-
isAbsolute(normalizedOptions.packageJsonPath) ? normalizedOptions.packageJsonPath : joinPaths(config.workspaceRoot, normalizedOptions.packageJsonPath)
|
|
66
|
-
)
|
|
67
|
-
);
|
|
68
|
-
}
|
|
69
|
-
if (normalizedOptions.configPath) {
|
|
70
|
-
normalizedOptions.configPath = relative(
|
|
71
|
-
absoluteProjectRoot,
|
|
72
|
-
correctPaths(
|
|
73
|
-
isAbsolute(normalizedOptions.configPath) ? normalizedOptions.configPath : joinPaths(config.workspaceRoot, normalizedOptions.configPath)
|
|
74
|
-
)
|
|
75
|
-
);
|
|
76
|
-
}
|
|
77
|
-
if (normalizedOptions.manifestPath) {
|
|
78
|
-
normalizedOptions.manifestPath = relative(
|
|
79
|
-
absoluteProjectRoot,
|
|
80
|
-
correctPaths(
|
|
81
|
-
isAbsolute(normalizedOptions.manifestPath) ? normalizedOptions.manifestPath : joinPaths(config.workspaceRoot, normalizedOptions.manifestPath)
|
|
82
|
-
)
|
|
83
|
-
);
|
|
84
|
-
}
|
|
85
|
-
}
|
|
86
|
-
if (process.env.VERCEL) {
|
|
87
|
-
return { success: true };
|
|
88
|
-
}
|
|
89
|
-
const { task } = await napi.build(normalizedOptions);
|
|
90
|
-
return { success: true, terminalOutput: await task };
|
|
91
|
-
}
|
|
92
|
-
var executor_default = withRunExecutor(
|
|
93
|
-
"Napi - Build Bindings",
|
|
94
|
-
napiExecutor,
|
|
95
|
-
{
|
|
96
|
-
skipReadingConfig: false,
|
|
97
|
-
hooks: {
|
|
98
|
-
applyDefaultOptions: (options) => {
|
|
99
|
-
options.outputPath ??= "{sourceRoot}";
|
|
100
|
-
options.toolchain ??= "stable";
|
|
101
|
-
options.dtsCache ??= true;
|
|
102
|
-
options.platform ??= true;
|
|
103
|
-
options.constEnum ??= false;
|
|
104
|
-
options.verbose ??= false;
|
|
105
|
-
options.jsBinding ??= "binding.js";
|
|
106
|
-
options.dts ??= "binding.d.ts";
|
|
107
|
-
return options;
|
|
108
|
-
}
|
|
109
|
-
}
|
|
110
|
-
}
|
|
111
|
-
);
|
|
112
|
-
|
|
113
|
-
export {
|
|
114
|
-
napiExecutor,
|
|
115
|
-
executor_default
|
|
116
|
-
};
|
package/dist/chunk-GVNAKGP4.mjs
DELETED
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
withRunExecutor
|
|
3
|
-
} from "./chunk-QOQ7ZZDR.mjs";
|
|
4
|
-
import {
|
|
5
|
-
buildCargoCommand,
|
|
6
|
-
cargoCommand
|
|
7
|
-
} from "./chunk-ZTN2676G.mjs";
|
|
8
|
-
|
|
9
|
-
// src/executors/cargo-check/executor.ts
|
|
10
|
-
async function cargoCheckExecutor(options, context) {
|
|
11
|
-
const command = buildCargoCommand("check", options, context);
|
|
12
|
-
return await cargoCommand(context.root, ...command);
|
|
13
|
-
}
|
|
14
|
-
var executor_default = withRunExecutor(
|
|
15
|
-
"Cargo - Check",
|
|
16
|
-
cargoCheckExecutor,
|
|
17
|
-
{
|
|
18
|
-
skipReadingConfig: false,
|
|
19
|
-
hooks: {
|
|
20
|
-
applyDefaultOptions: (options) => {
|
|
21
|
-
options.toolchain ??= "stable";
|
|
22
|
-
return options;
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
);
|
|
27
|
-
|
|
28
|
-
export {
|
|
29
|
-
cargoCheckExecutor,
|
|
30
|
-
executor_default
|
|
31
|
-
};
|
package/dist/chunk-H4MADHCO.js
DELETED
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
|
-
|
|
3
|
-
var _chunkRO2CCHL3js = require('./chunk-RO2CCHL3.js');
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
var _chunkD2PV33E5js = require('./chunk-D2PV33E5.js');
|
|
8
|
-
|
|
9
|
-
// src/executors/cargo-clippy/executor.ts
|
|
10
|
-
async function cargoClippyExecutor(options, context) {
|
|
11
|
-
const command = _chunkD2PV33E5js.buildCargoCommand.call(void 0, "clippy", options, context);
|
|
12
|
-
return await _chunkD2PV33E5js.cargoCommand.call(void 0, context.root, ...command);
|
|
13
|
-
}
|
|
14
|
-
var executor_default = _chunkRO2CCHL3js.withRunExecutor.call(void 0,
|
|
15
|
-
"Cargo - Clippy",
|
|
16
|
-
cargoClippyExecutor,
|
|
17
|
-
{
|
|
18
|
-
skipReadingConfig: false,
|
|
19
|
-
hooks: {
|
|
20
|
-
applyDefaultOptions: (options) => {
|
|
21
|
-
options.toolchain ??= "stable";
|
|
22
|
-
options.fix ??= false;
|
|
23
|
-
return options;
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
);
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
exports.cargoClippyExecutor = cargoClippyExecutor; exports.executor_default = executor_default;
|
package/dist/chunk-LWYN4MTV.js
DELETED
|
@@ -1,79 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } }
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
var _chunkBZMYB75Mjs = require('./chunk-BZMYB75M.js');
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
var _chunkFR2SIPZVjs = require('./chunk-FR2SIPZV.js');
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
var _chunkSZWM7COVjs = require('./chunk-SZWM7COV.js');
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
var _chunkCQDBLKPFjs = require('./chunk-CQDBLKPF.js');
|
|
14
|
-
|
|
15
|
-
// src/generators/node-library/generator.ts
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
var _devkit = require('@nx/devkit');
|
|
22
|
-
async function nodeLibraryGeneratorFn(tree, schema, config) {
|
|
23
|
-
const filesDir = _chunkCQDBLKPFjs.joinPaths.call(void 0,
|
|
24
|
-
__dirname,
|
|
25
|
-
"src",
|
|
26
|
-
"generators",
|
|
27
|
-
"node-library",
|
|
28
|
-
"files"
|
|
29
|
-
);
|
|
30
|
-
const tsLibraryGeneratorOptions = {
|
|
31
|
-
platform: "node",
|
|
32
|
-
devDependencies: {
|
|
33
|
-
"@types/node": _chunkSZWM7COVjs.typesNodeVersion
|
|
34
|
-
},
|
|
35
|
-
buildExecutor: "@storm-software/workspace-tools:unbuild",
|
|
36
|
-
...schema,
|
|
37
|
-
directory: schema.directory,
|
|
38
|
-
description: schema.description
|
|
39
|
-
};
|
|
40
|
-
const options = await _chunkBZMYB75Mjs.normalizeOptions.call(void 0, tree, tsLibraryGeneratorOptions);
|
|
41
|
-
const { className, name, propertyName } = _devkit.names.call(void 0, options.name);
|
|
42
|
-
_devkit.generateFiles.call(void 0, tree, filesDir, options.projectRoot, {
|
|
43
|
-
...schema,
|
|
44
|
-
dot: ".",
|
|
45
|
-
className,
|
|
46
|
-
name,
|
|
47
|
-
namespace: _nullishCoalesce(process.env.STORM_NAMESPACE, () => ( "storm-software")),
|
|
48
|
-
description: _nullishCoalesce(schema.description, () => ( "")),
|
|
49
|
-
propertyName,
|
|
50
|
-
js: !!options.js,
|
|
51
|
-
cliCommand: "nx",
|
|
52
|
-
strict: void 0,
|
|
53
|
-
tmpl: "",
|
|
54
|
-
offsetFromRoot: _devkit.offsetFromRoot.call(void 0, options.projectRoot),
|
|
55
|
-
buildable: options.bundler && options.bundler !== "none",
|
|
56
|
-
hasUnitTestRunner: options.unitTestRunner !== "none"
|
|
57
|
-
});
|
|
58
|
-
await _chunkBZMYB75Mjs.typeScriptLibraryGeneratorFn.call(void 0, tree, tsLibraryGeneratorOptions, config);
|
|
59
|
-
await _devkit.formatFiles.call(void 0, tree);
|
|
60
|
-
return null;
|
|
61
|
-
}
|
|
62
|
-
var generator_default = _chunkFR2SIPZVjs.withRunGenerator.call(void 0,
|
|
63
|
-
"TypeScript Library Creator (NodeJs Platform)",
|
|
64
|
-
nodeLibraryGeneratorFn,
|
|
65
|
-
{
|
|
66
|
-
hooks: {
|
|
67
|
-
applyDefaultOptions: (options) => {
|
|
68
|
-
options.description ??= "A library used by Storm Software to support NodeJs applications";
|
|
69
|
-
options.platform ??= "node";
|
|
70
|
-
return options;
|
|
71
|
-
}
|
|
72
|
-
}
|
|
73
|
-
}
|
|
74
|
-
);
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
exports.nodeLibraryGeneratorFn = nodeLibraryGeneratorFn; exports.generator_default = generator_default;
|