@powerlines/nx 0.11.217 → 0.11.219
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 +16 -0
- package/dist/chunk-3BI2YVJ3.js +156 -0
- package/dist/{chunk-AQU4Y7TY.mjs → chunk-4KF5AUPD.mjs} +1 -1
- package/dist/chunk-4OMPO3GC.mjs +154 -0
- package/dist/{chunk-MMYSL52M.mjs → chunk-7EWOPOET.mjs} +220 -388
- package/dist/{chunk-JQZOWO7J.mjs → chunk-FIOTA3DI.mjs} +1 -1
- package/dist/chunk-FSGRYCTL.js +281 -0
- package/dist/{chunk-UWZA4FE6.mjs → chunk-GB6SETBZ.mjs} +1 -1
- package/dist/{chunk-2YJP4HRC.mjs → chunk-GCIPEE4T.mjs} +7 -7
- package/dist/{chunk-WJP3FWAH.js → chunk-GJ62I4AV.js} +2 -2
- package/dist/chunk-HNRM52ID.js +374 -0
- package/dist/chunk-IA3YWWWC.mjs +366 -0
- package/dist/{chunk-VSMLSWBT.js → chunk-IOBDAGVL.js} +8 -8
- package/dist/chunk-JL4HQ7ZD.mjs +260 -0
- package/dist/{chunk-5XND6U2P.js → chunk-K6HPKAIP.js} +2 -2
- package/dist/{chunk-TL367T24.js → chunk-KAY4UTGV.js} +2 -2
- package/dist/{chunk-2OUVFH73.js → chunk-MYNOF2F6.js} +2 -2
- package/dist/{chunk-5QDW5A4Z.js → chunk-QA32JCA6.js} +2 -2
- package/dist/{chunk-ELBUYWVF.mjs → chunk-QN6ZKFPV.mjs} +1 -1
- package/dist/{chunk-BUUW4BAS.mjs → chunk-RLKRZBG3.mjs} +2 -2
- package/dist/{chunk-C4XEVBMI.mjs → chunk-ULCS2R4D.mjs} +1 -1
- package/dist/{chunk-QJE3HWRQ.js → chunk-WXALQB3J.js} +3 -3
- package/dist/{chunk-BM4NZS6T.js → chunk-ZODDB4GG.js} +244 -412
- package/dist/{executor-Bb8vGV8C.d.ts → executor-AQVlPFta.d.ts} +90 -19
- package/dist/{executor-CQzw0-So.d.mts → executor-BNmIhtpF.d.mts} +90 -19
- package/dist/{executor-DwTFXSVb.d.mts → executor-C0A5mFLO.d.mts} +74 -19
- package/dist/{executor-u-vw0Uzf.d.mts → executor-Cep8-Y3A.d.mts} +90 -19
- package/dist/{executor-DY7vA66P.d.ts → executor-CkyahICv.d.ts} +74 -19
- package/dist/{executor-C2WSCUOW.d.ts → executor-DOsxw-Ih.d.ts} +90 -19
- package/dist/{executor-C5rCem7d.d.ts → executor-DUQbjUVt.d.ts} +90 -19
- package/dist/{executor-C9MI57kJ.d.ts → executor-O3MDQSFT.d.ts} +90 -19
- package/dist/{executor-fccJAIjg.d.mts → executor-U4mVkhQK.d.mts} +90 -19
- package/dist/{executor-DXaEo8YG.d.mts → executor-Xt5qNzC5.d.mts} +90 -19
- package/dist/executors.d.mts +5 -6
- package/dist/executors.d.ts +5 -6
- package/dist/executors.js +12 -12
- package/dist/executors.mjs +7 -7
- package/dist/index.d.mts +5 -6
- package/dist/index.d.ts +5 -6
- package/dist/index.js +15 -15
- package/dist/index.mjs +9 -9
- package/dist/src/base/base-executor.d.mts +1 -2
- package/dist/src/base/base-executor.d.ts +1 -2
- package/dist/src/base/base-executor.js +3 -3
- package/dist/src/base/base-executor.mjs +2 -2
- package/dist/src/base/base-executor.schema.d.d.mts +74 -19
- package/dist/src/base/base-executor.schema.d.d.ts +74 -19
- package/dist/src/base/base-executor.schema.d.ts +74 -19
- package/dist/src/base/base-executor.schema.json +108 -26
- package/dist/src/base/base-executor.untyped.js +2 -2
- package/dist/src/base/base-executor.untyped.mjs +1 -1
- package/dist/src/executors/build/executor.d.mts +1 -2
- package/dist/src/executors/build/executor.d.ts +1 -2
- package/dist/src/executors/build/executor.js +5 -5
- package/dist/src/executors/build/executor.mjs +3 -3
- package/dist/src/executors/build/schema.d.ts +90 -19
- package/dist/src/executors/build/schema.json +119 -25
- package/dist/src/executors/build/untyped.js +3 -3
- package/dist/src/executors/build/untyped.mjs +2 -2
- package/dist/src/executors/clean/executor.d.mts +1 -2
- package/dist/src/executors/clean/executor.d.ts +1 -2
- package/dist/src/executors/clean/executor.js +5 -5
- package/dist/src/executors/clean/executor.mjs +3 -3
- package/dist/src/executors/clean/schema.d.ts +74 -19
- package/dist/src/executors/clean/schema.json +108 -26
- package/dist/src/executors/clean/untyped.js +2 -2
- package/dist/src/executors/clean/untyped.mjs +1 -1
- package/dist/src/executors/docs/executor.d.mts +1 -2
- package/dist/src/executors/docs/executor.d.ts +1 -2
- package/dist/src/executors/docs/executor.js +5 -5
- package/dist/src/executors/docs/executor.mjs +3 -3
- package/dist/src/executors/docs/schema.d.ts +90 -19
- package/dist/src/executors/docs/schema.json +120 -26
- package/dist/src/executors/docs/untyped.js +3 -3
- package/dist/src/executors/docs/untyped.mjs +2 -2
- package/dist/src/executors/lint/executor.d.mts +1 -2
- package/dist/src/executors/lint/executor.d.ts +1 -2
- package/dist/src/executors/lint/executor.js +5 -5
- package/dist/src/executors/lint/executor.mjs +3 -3
- package/dist/src/executors/lint/schema.d.ts +90 -19
- package/dist/src/executors/lint/schema.json +120 -26
- package/dist/src/executors/lint/untyped.js +3 -3
- package/dist/src/executors/lint/untyped.mjs +2 -2
- package/dist/src/executors/prepare/executor.d.mts +1 -2
- package/dist/src/executors/prepare/executor.d.ts +1 -2
- package/dist/src/executors/prepare/executor.js +5 -5
- package/dist/src/executors/prepare/executor.mjs +3 -3
- package/dist/src/executors/prepare/schema.d.ts +90 -19
- package/dist/src/executors/prepare/schema.json +120 -26
- package/dist/src/executors/prepare/untyped.js +3 -3
- package/dist/src/executors/prepare/untyped.mjs +2 -2
- package/dist/src/helpers/plugin-utilities.d.mts +1 -1
- package/dist/src/helpers/plugin-utilities.d.ts +1 -1
- package/dist/src/helpers/plugin-utilities.js +5 -5
- package/dist/src/helpers/plugin-utilities.mjs +2 -2
- package/dist/src/plugin/index.js +4 -4
- package/dist/src/plugin/index.mjs +3 -3
- package/docs/api/base-executor.schema.md +71 -19
- package/docs/api/build/schema.md +89 -19
- package/docs/api/clean/schema.md +71 -19
- package/docs/api/docs/schema.md +89 -19
- package/docs/api/lint/schema.md +89 -19
- package/docs/api/prepare/schema.md +89 -19
- package/package.json +11 -11
- package/dist/chunk-AGZ4P3AS.mjs +0 -87
- package/dist/chunk-IR6TAW72.js +0 -81
- package/dist/chunk-NU3VTAH5.js +0 -98
- package/dist/chunk-TWOXCXFE.js +0 -364
- package/dist/chunk-XXWF7X5C.mjs +0 -75
- package/dist/chunk-ZYOL33SX.mjs +0 -356
package/dist/chunk-AGZ4P3AS.mjs
DELETED
|
@@ -1,87 +0,0 @@
|
|
|
1
|
-
import { __name } from './chunk-O6YSETKJ.mjs';
|
|
2
|
-
import { getWorkspaceConfig } from '@storm-software/config-tools/get-config';
|
|
3
|
-
import { existsSync } from '@stryke/fs/exists';
|
|
4
|
-
import { appendPath } from '@stryke/path/append';
|
|
5
|
-
import { joinPaths } from '@stryke/path/join-paths';
|
|
6
|
-
import { replacePath } from '@stryke/path/replace';
|
|
7
|
-
import { isFunction } from '@stryke/type-checks/is-function';
|
|
8
|
-
import { isSetObject } from '@stryke/type-checks/is-set-object';
|
|
9
|
-
import { loadConfig } from 'c12';
|
|
10
|
-
import defu from 'defu';
|
|
11
|
-
import '@stryke/fs/json';
|
|
12
|
-
import '@stryke/fs/list-files';
|
|
13
|
-
import '@stryke/fs/remove-file';
|
|
14
|
-
import '@stryke/helpers/get-unique';
|
|
15
|
-
import '@stryke/path/file-path-fns';
|
|
16
|
-
import { kebabCase } from '@stryke/string-format/kebab-case';
|
|
17
|
-
|
|
18
|
-
async function loadWorkspaceConfig(workspaceRoot, cwd) {
|
|
19
|
-
return defu({
|
|
20
|
-
workspaceRoot
|
|
21
|
-
}, await getWorkspaceConfig(true, {
|
|
22
|
-
cwd,
|
|
23
|
-
workspaceRoot,
|
|
24
|
-
useDefault: true
|
|
25
|
-
}));
|
|
26
|
-
}
|
|
27
|
-
__name(loadWorkspaceConfig, "loadWorkspaceConfig");
|
|
28
|
-
async function loadUserConfigFile(projectRoot, workspaceRoot, jiti, command, mode = "production", configFile, framework = "powerlines") {
|
|
29
|
-
let resolvedUserConfig = {};
|
|
30
|
-
let resolvedUserConfigFile;
|
|
31
|
-
if (configFile) {
|
|
32
|
-
resolvedUserConfigFile = existsSync(replacePath(configFile, projectRoot)) ? replacePath(configFile, projectRoot) : existsSync(joinPaths(appendPath(projectRoot, workspaceRoot), replacePath(configFile, projectRoot))) ? joinPaths(appendPath(projectRoot, workspaceRoot), replacePath(configFile, projectRoot)) : existsSync(joinPaths(appendPath(projectRoot, workspaceRoot), configFile)) ? joinPaths(appendPath(projectRoot, workspaceRoot), configFile) : void 0;
|
|
33
|
-
}
|
|
34
|
-
if (!resolvedUserConfigFile) {
|
|
35
|
-
resolvedUserConfigFile = existsSync(joinPaths(appendPath(projectRoot, workspaceRoot), `${framework}.${mode}.config.ts`)) ? joinPaths(appendPath(projectRoot, workspaceRoot), `${framework}.${mode}.config.ts`) : existsSync(joinPaths(appendPath(projectRoot, workspaceRoot), `${framework}.${mode}.config.js`)) ? joinPaths(appendPath(projectRoot, workspaceRoot), `${framework}.${mode}.config.js`) : existsSync(joinPaths(appendPath(projectRoot, workspaceRoot), `${framework}.${mode}.config.mts`)) ? joinPaths(appendPath(projectRoot, workspaceRoot), `${framework}.${mode}.config.mts`) : existsSync(joinPaths(appendPath(projectRoot, workspaceRoot), `${framework}.${mode}.config.mjs`)) ? joinPaths(appendPath(projectRoot, workspaceRoot), `${framework}.${mode}.config.mjs`) : existsSync(joinPaths(appendPath(projectRoot, workspaceRoot), `${framework}.config.ts`)) ? joinPaths(appendPath(projectRoot, workspaceRoot), `${framework}.config.ts`) : existsSync(joinPaths(appendPath(projectRoot, workspaceRoot), `${framework}.config.js`)) ? joinPaths(appendPath(projectRoot, workspaceRoot), `${framework}.config.js`) : existsSync(joinPaths(appendPath(projectRoot, workspaceRoot), `${framework}.config.mts`)) ? joinPaths(appendPath(projectRoot, workspaceRoot), `${framework}.config.mts`) : existsSync(joinPaths(appendPath(projectRoot, workspaceRoot), `${framework}.config.mjs`)) ? joinPaths(appendPath(projectRoot, workspaceRoot), `${framework}.config.mjs`) : void 0;
|
|
36
|
-
}
|
|
37
|
-
if (resolvedUserConfigFile) {
|
|
38
|
-
const resolved = await jiti.import(jiti.esmResolve(resolvedUserConfigFile));
|
|
39
|
-
if (resolved) {
|
|
40
|
-
let config = {};
|
|
41
|
-
if (isFunction(resolved)) {
|
|
42
|
-
config = await Promise.resolve(resolved({
|
|
43
|
-
command,
|
|
44
|
-
mode,
|
|
45
|
-
isSsrBuild: false,
|
|
46
|
-
isPreview: false
|
|
47
|
-
}));
|
|
48
|
-
}
|
|
49
|
-
if (isSetObject(config)) {
|
|
50
|
-
resolvedUserConfig = {
|
|
51
|
-
...config,
|
|
52
|
-
config,
|
|
53
|
-
configFile: resolvedUserConfigFile
|
|
54
|
-
};
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
}
|
|
58
|
-
const result = await loadConfig({
|
|
59
|
-
cwd: projectRoot,
|
|
60
|
-
name: framework,
|
|
61
|
-
envName: mode,
|
|
62
|
-
globalRc: true,
|
|
63
|
-
packageJson: true,
|
|
64
|
-
dotenv: true,
|
|
65
|
-
jiti
|
|
66
|
-
});
|
|
67
|
-
return defu(resolvedUserConfig, isSetObject(result?.config) ? {
|
|
68
|
-
...result.config,
|
|
69
|
-
...result
|
|
70
|
-
} : {});
|
|
71
|
-
}
|
|
72
|
-
__name(loadUserConfigFile, "loadUserConfigFile");
|
|
73
|
-
var PROJECT_ROOT_HASH_LENGTH = 45;
|
|
74
|
-
var CACHE_HASH_LENGTH = 62;
|
|
75
|
-
function getPrefixedProjectRootHash(name, projectRootHash) {
|
|
76
|
-
const combined = `${kebabCase(name)}_${projectRootHash}`;
|
|
77
|
-
return combined.length > PROJECT_ROOT_HASH_LENGTH ? combined.slice(0, PROJECT_ROOT_HASH_LENGTH) : combined;
|
|
78
|
-
}
|
|
79
|
-
__name(getPrefixedProjectRootHash, "getPrefixedProjectRootHash");
|
|
80
|
-
async function writeMetaFile(context) {
|
|
81
|
-
const metaFilePath = joinPaths(context.dataPath, "meta.json");
|
|
82
|
-
context.debug(`Writing runtime metadata to ${metaFilePath}`);
|
|
83
|
-
await context.fs.write(metaFilePath, JSON.stringify(context.meta, null, 2));
|
|
84
|
-
}
|
|
85
|
-
__name(writeMetaFile, "writeMetaFile");
|
|
86
|
-
|
|
87
|
-
export { CACHE_HASH_LENGTH, PROJECT_ROOT_HASH_LENGTH, getPrefixedProjectRootHash, loadUserConfigFile, loadWorkspaceConfig, writeMetaFile };
|
package/dist/chunk-IR6TAW72.js
DELETED
|
@@ -1,81 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
var baseExecutorSchema = require('@storm-software/workspace-tools/base/base-executor.untyped');
|
|
4
|
-
var untyped = require('untyped');
|
|
5
|
-
|
|
6
|
-
function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }
|
|
7
|
-
|
|
8
|
-
var baseExecutorSchema__default = /*#__PURE__*/_interopDefault(baseExecutorSchema);
|
|
9
|
-
|
|
10
|
-
// src/base/base-executor.untyped.ts
|
|
11
|
-
var base_executor_untyped_default = untyped.defineUntypedSchema({
|
|
12
|
-
...baseExecutorSchema__default.default,
|
|
13
|
-
$schema: {
|
|
14
|
-
id: "BaseExecutorSchema",
|
|
15
|
-
title: "Base Executor",
|
|
16
|
-
description: "A shared/base schema type definition for Powerlines executors",
|
|
17
|
-
required: []
|
|
18
|
-
},
|
|
19
|
-
tsconfig: {
|
|
20
|
-
$schema: {
|
|
21
|
-
title: "TypeScript Configuration File",
|
|
22
|
-
type: "string",
|
|
23
|
-
format: "path",
|
|
24
|
-
description: "The path to the tsconfig file"
|
|
25
|
-
}
|
|
26
|
-
},
|
|
27
|
-
configFile: {
|
|
28
|
-
$schema: {
|
|
29
|
-
title: "Powerlines Configuration File",
|
|
30
|
-
type: "string",
|
|
31
|
-
format: "path",
|
|
32
|
-
description: "The path to the Powerlines configuration file"
|
|
33
|
-
},
|
|
34
|
-
$default: "{projectRoot}/powerlines.config.ts"
|
|
35
|
-
},
|
|
36
|
-
mode: {
|
|
37
|
-
$schema: {
|
|
38
|
-
title: "Mode",
|
|
39
|
-
type: "string",
|
|
40
|
-
description: "The build mode",
|
|
41
|
-
enum: [
|
|
42
|
-
"development",
|
|
43
|
-
"test",
|
|
44
|
-
"production"
|
|
45
|
-
]
|
|
46
|
-
}
|
|
47
|
-
},
|
|
48
|
-
autoInstall: {
|
|
49
|
-
$schema: {
|
|
50
|
-
title: "Auto Install",
|
|
51
|
-
type: "boolean",
|
|
52
|
-
description: "Automatically install dependencies during prepare stage"
|
|
53
|
-
}
|
|
54
|
-
},
|
|
55
|
-
skipCache: {
|
|
56
|
-
$schema: {
|
|
57
|
-
title: "Skip Cache",
|
|
58
|
-
type: "boolean",
|
|
59
|
-
description: "Skip the caching mechanism during the build process (if required)"
|
|
60
|
-
}
|
|
61
|
-
},
|
|
62
|
-
logLevel: {
|
|
63
|
-
$schema: {
|
|
64
|
-
title: "Log Level",
|
|
65
|
-
type: "string",
|
|
66
|
-
description: "The log level to use for the build process",
|
|
67
|
-
enum: [
|
|
68
|
-
"fatal",
|
|
69
|
-
"error",
|
|
70
|
-
"warn",
|
|
71
|
-
"success",
|
|
72
|
-
"info",
|
|
73
|
-
"debug",
|
|
74
|
-
"trace",
|
|
75
|
-
"silent"
|
|
76
|
-
]
|
|
77
|
-
}
|
|
78
|
-
}
|
|
79
|
-
});
|
|
80
|
-
|
|
81
|
-
exports.base_executor_untyped_default = base_executor_untyped_default;
|
package/dist/chunk-NU3VTAH5.js
DELETED
|
@@ -1,98 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
var chunkSHUYVCID_js = require('./chunk-SHUYVCID.js');
|
|
4
|
-
var getConfig = require('@storm-software/config-tools/get-config');
|
|
5
|
-
var exists = require('@stryke/fs/exists');
|
|
6
|
-
var append = require('@stryke/path/append');
|
|
7
|
-
var joinPaths = require('@stryke/path/join-paths');
|
|
8
|
-
var replace = require('@stryke/path/replace');
|
|
9
|
-
var isFunction = require('@stryke/type-checks/is-function');
|
|
10
|
-
var isSetObject = require('@stryke/type-checks/is-set-object');
|
|
11
|
-
var c12 = require('c12');
|
|
12
|
-
var defu = require('defu');
|
|
13
|
-
require('@stryke/fs/json');
|
|
14
|
-
require('@stryke/fs/list-files');
|
|
15
|
-
require('@stryke/fs/remove-file');
|
|
16
|
-
require('@stryke/helpers/get-unique');
|
|
17
|
-
require('@stryke/path/file-path-fns');
|
|
18
|
-
var kebabCase = require('@stryke/string-format/kebab-case');
|
|
19
|
-
|
|
20
|
-
function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }
|
|
21
|
-
|
|
22
|
-
var defu__default = /*#__PURE__*/_interopDefault(defu);
|
|
23
|
-
|
|
24
|
-
async function loadWorkspaceConfig(workspaceRoot, cwd) {
|
|
25
|
-
return defu__default.default({
|
|
26
|
-
workspaceRoot
|
|
27
|
-
}, await getConfig.getWorkspaceConfig(true, {
|
|
28
|
-
cwd,
|
|
29
|
-
workspaceRoot,
|
|
30
|
-
useDefault: true
|
|
31
|
-
}));
|
|
32
|
-
}
|
|
33
|
-
chunkSHUYVCID_js.__name(loadWorkspaceConfig, "loadWorkspaceConfig");
|
|
34
|
-
async function loadUserConfigFile(projectRoot, workspaceRoot, jiti, command, mode = "production", configFile, framework = "powerlines") {
|
|
35
|
-
let resolvedUserConfig = {};
|
|
36
|
-
let resolvedUserConfigFile;
|
|
37
|
-
if (configFile) {
|
|
38
|
-
resolvedUserConfigFile = exists.existsSync(replace.replacePath(configFile, projectRoot)) ? replace.replacePath(configFile, projectRoot) : exists.existsSync(joinPaths.joinPaths(append.appendPath(projectRoot, workspaceRoot), replace.replacePath(configFile, projectRoot))) ? joinPaths.joinPaths(append.appendPath(projectRoot, workspaceRoot), replace.replacePath(configFile, projectRoot)) : exists.existsSync(joinPaths.joinPaths(append.appendPath(projectRoot, workspaceRoot), configFile)) ? joinPaths.joinPaths(append.appendPath(projectRoot, workspaceRoot), configFile) : void 0;
|
|
39
|
-
}
|
|
40
|
-
if (!resolvedUserConfigFile) {
|
|
41
|
-
resolvedUserConfigFile = exists.existsSync(joinPaths.joinPaths(append.appendPath(projectRoot, workspaceRoot), `${framework}.${mode}.config.ts`)) ? joinPaths.joinPaths(append.appendPath(projectRoot, workspaceRoot), `${framework}.${mode}.config.ts`) : exists.existsSync(joinPaths.joinPaths(append.appendPath(projectRoot, workspaceRoot), `${framework}.${mode}.config.js`)) ? joinPaths.joinPaths(append.appendPath(projectRoot, workspaceRoot), `${framework}.${mode}.config.js`) : exists.existsSync(joinPaths.joinPaths(append.appendPath(projectRoot, workspaceRoot), `${framework}.${mode}.config.mts`)) ? joinPaths.joinPaths(append.appendPath(projectRoot, workspaceRoot), `${framework}.${mode}.config.mts`) : exists.existsSync(joinPaths.joinPaths(append.appendPath(projectRoot, workspaceRoot), `${framework}.${mode}.config.mjs`)) ? joinPaths.joinPaths(append.appendPath(projectRoot, workspaceRoot), `${framework}.${mode}.config.mjs`) : exists.existsSync(joinPaths.joinPaths(append.appendPath(projectRoot, workspaceRoot), `${framework}.config.ts`)) ? joinPaths.joinPaths(append.appendPath(projectRoot, workspaceRoot), `${framework}.config.ts`) : exists.existsSync(joinPaths.joinPaths(append.appendPath(projectRoot, workspaceRoot), `${framework}.config.js`)) ? joinPaths.joinPaths(append.appendPath(projectRoot, workspaceRoot), `${framework}.config.js`) : exists.existsSync(joinPaths.joinPaths(append.appendPath(projectRoot, workspaceRoot), `${framework}.config.mts`)) ? joinPaths.joinPaths(append.appendPath(projectRoot, workspaceRoot), `${framework}.config.mts`) : exists.existsSync(joinPaths.joinPaths(append.appendPath(projectRoot, workspaceRoot), `${framework}.config.mjs`)) ? joinPaths.joinPaths(append.appendPath(projectRoot, workspaceRoot), `${framework}.config.mjs`) : void 0;
|
|
42
|
-
}
|
|
43
|
-
if (resolvedUserConfigFile) {
|
|
44
|
-
const resolved = await jiti.import(jiti.esmResolve(resolvedUserConfigFile));
|
|
45
|
-
if (resolved) {
|
|
46
|
-
let config = {};
|
|
47
|
-
if (isFunction.isFunction(resolved)) {
|
|
48
|
-
config = await Promise.resolve(resolved({
|
|
49
|
-
command,
|
|
50
|
-
mode,
|
|
51
|
-
isSsrBuild: false,
|
|
52
|
-
isPreview: false
|
|
53
|
-
}));
|
|
54
|
-
}
|
|
55
|
-
if (isSetObject.isSetObject(config)) {
|
|
56
|
-
resolvedUserConfig = {
|
|
57
|
-
...config,
|
|
58
|
-
config,
|
|
59
|
-
configFile: resolvedUserConfigFile
|
|
60
|
-
};
|
|
61
|
-
}
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
const result = await c12.loadConfig({
|
|
65
|
-
cwd: projectRoot,
|
|
66
|
-
name: framework,
|
|
67
|
-
envName: mode,
|
|
68
|
-
globalRc: true,
|
|
69
|
-
packageJson: true,
|
|
70
|
-
dotenv: true,
|
|
71
|
-
jiti
|
|
72
|
-
});
|
|
73
|
-
return defu__default.default(resolvedUserConfig, isSetObject.isSetObject(result?.config) ? {
|
|
74
|
-
...result.config,
|
|
75
|
-
...result
|
|
76
|
-
} : {});
|
|
77
|
-
}
|
|
78
|
-
chunkSHUYVCID_js.__name(loadUserConfigFile, "loadUserConfigFile");
|
|
79
|
-
var PROJECT_ROOT_HASH_LENGTH = 45;
|
|
80
|
-
var CACHE_HASH_LENGTH = 62;
|
|
81
|
-
function getPrefixedProjectRootHash(name, projectRootHash) {
|
|
82
|
-
const combined = `${kebabCase.kebabCase(name)}_${projectRootHash}`;
|
|
83
|
-
return combined.length > PROJECT_ROOT_HASH_LENGTH ? combined.slice(0, PROJECT_ROOT_HASH_LENGTH) : combined;
|
|
84
|
-
}
|
|
85
|
-
chunkSHUYVCID_js.__name(getPrefixedProjectRootHash, "getPrefixedProjectRootHash");
|
|
86
|
-
async function writeMetaFile(context) {
|
|
87
|
-
const metaFilePath = joinPaths.joinPaths(context.dataPath, "meta.json");
|
|
88
|
-
context.debug(`Writing runtime metadata to ${metaFilePath}`);
|
|
89
|
-
await context.fs.write(metaFilePath, JSON.stringify(context.meta, null, 2));
|
|
90
|
-
}
|
|
91
|
-
chunkSHUYVCID_js.__name(writeMetaFile, "writeMetaFile");
|
|
92
|
-
|
|
93
|
-
exports.CACHE_HASH_LENGTH = CACHE_HASH_LENGTH;
|
|
94
|
-
exports.PROJECT_ROOT_HASH_LENGTH = PROJECT_ROOT_HASH_LENGTH;
|
|
95
|
-
exports.getPrefixedProjectRootHash = getPrefixedProjectRootHash;
|
|
96
|
-
exports.loadUserConfigFile = loadUserConfigFile;
|
|
97
|
-
exports.loadWorkspaceConfig = loadWorkspaceConfig;
|
|
98
|
-
exports.writeMetaFile = writeMetaFile;
|
package/dist/chunk-TWOXCXFE.js
DELETED
|
@@ -1,364 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
var chunkNU3VTAH5_js = require('./chunk-NU3VTAH5.js');
|
|
4
|
-
var chunkIQVSZEQ6_js = require('./chunk-IQVSZEQ6.js');
|
|
5
|
-
var chunkSHUYVCID_js = require('./chunk-SHUYVCID.js');
|
|
6
|
-
var devkit = require('@nx/devkit');
|
|
7
|
-
var nxJson = require('@storm-software/workspace-tools/utils/nx-json');
|
|
8
|
-
var pluginHelpers = require('@storm-software/workspace-tools/utils/plugin-helpers');
|
|
9
|
-
var projectTags = require('@storm-software/workspace-tools/utils/project-tags');
|
|
10
|
-
var getEnvPaths = require('@stryke/env/get-env-paths');
|
|
11
|
-
var exists = require('@stryke/fs/exists');
|
|
12
|
-
var murmurhash = require('@stryke/hash/murmurhash');
|
|
13
|
-
var joinPaths = require('@stryke/path/join-paths');
|
|
14
|
-
var kebabCase = require('@stryke/string-format/kebab-case');
|
|
15
|
-
var titleCase = require('@stryke/string-format/title-case');
|
|
16
|
-
var isError = require('@stryke/type-checks/is-error');
|
|
17
|
-
var isSetObject = require('@stryke/type-checks/is-set-object');
|
|
18
|
-
var defu = require('defu');
|
|
19
|
-
var jiti = require('jiti');
|
|
20
|
-
var promises = require('fs/promises');
|
|
21
|
-
var nxJson_js = require('nx/src/config/nx-json.js');
|
|
22
|
-
var packageJson_js = require('nx/src/utils/package-json.js');
|
|
23
|
-
|
|
24
|
-
function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }
|
|
25
|
-
|
|
26
|
-
var defu__default = /*#__PURE__*/_interopDefault(defu);
|
|
27
|
-
|
|
28
|
-
function getNxTargetInputs(framework) {
|
|
29
|
-
return chunkIQVSZEQ6_js.CONFIG_INPUTS.map((input) => input.replace("{framework}", framework));
|
|
30
|
-
}
|
|
31
|
-
chunkSHUYVCID_js.__name(getNxTargetInputs, "getNxTargetInputs");
|
|
32
|
-
function getNxPluginInputs(framework) {
|
|
33
|
-
return `**/{${getNxTargetInputs(framework).map((input) => input.replace("{projectRoot}/", "")).join(",")}}`;
|
|
34
|
-
}
|
|
35
|
-
chunkSHUYVCID_js.__name(getNxPluginInputs, "getNxPluginInputs");
|
|
36
|
-
function createNxPlugin(opts) {
|
|
37
|
-
const framework = opts?.framework || "powerlines";
|
|
38
|
-
const name = opts?.name || `${framework}/nx/plugin`;
|
|
39
|
-
const artifactsFolder = opts?.artifactsFolder || `{projectRoot}/.${framework}`;
|
|
40
|
-
const targetInputs = getNxTargetInputs(framework);
|
|
41
|
-
const pluginInputs = getNxPluginInputs(framework);
|
|
42
|
-
if (opts?.verbose) {
|
|
43
|
-
console.debug(`[${name}] - ${(/* @__PURE__ */ new Date()).toISOString()} - Initializing the ${titleCase.titleCase(framework)} Nx plugin for the following inputs: ${pluginInputs}`);
|
|
44
|
-
}
|
|
45
|
-
return [
|
|
46
|
-
pluginInputs,
|
|
47
|
-
async (configFiles, options, contextV2) => {
|
|
48
|
-
const envPaths = getEnvPaths.getEnvPaths({
|
|
49
|
-
orgId: "storm-software",
|
|
50
|
-
appId: framework,
|
|
51
|
-
workspaceRoot: contextV2.workspaceRoot
|
|
52
|
-
});
|
|
53
|
-
if (!envPaths.cache) {
|
|
54
|
-
throw new Error("The cache directory could not be determined.");
|
|
55
|
-
}
|
|
56
|
-
const nxJson$1 = nxJson_js.readNxJson(contextV2.workspaceRoot);
|
|
57
|
-
const resolver = jiti.createJiti(contextV2.workspaceRoot, {
|
|
58
|
-
debug: !!options?.debug,
|
|
59
|
-
interopDefault: true,
|
|
60
|
-
fsCache: joinPaths.joinPaths(envPaths.cache, "nx-plugin", murmurhash.murmurhash(contextV2.workspaceRoot, {
|
|
61
|
-
maxLength: chunkNU3VTAH5_js.PROJECT_ROOT_HASH_LENGTH
|
|
62
|
-
}), "jiti"),
|
|
63
|
-
moduleCache: true
|
|
64
|
-
});
|
|
65
|
-
return devkit.createNodesFromFiles(async (configFile, _, context) => {
|
|
66
|
-
try {
|
|
67
|
-
const projectRoot = pluginHelpers.getProjectRoot(configFile, contextV2.workspaceRoot);
|
|
68
|
-
if (!projectRoot) {
|
|
69
|
-
console.error(`[${name}] - ${(/* @__PURE__ */ new Date()).toISOString()} - package.json and ${framework} configuration files (i.e. ${framework}.config.ts) must be located in the project root directory: ${configFile}`);
|
|
70
|
-
return {};
|
|
71
|
-
}
|
|
72
|
-
const root = pluginHelpers.getRoot(projectRoot, context);
|
|
73
|
-
if (opts?.verbose) {
|
|
74
|
-
console.debug(`[${name}] - ${(/* @__PURE__ */ new Date()).toISOString()} - Loading ${framework} user configuration for project in root directory ${projectRoot}.`);
|
|
75
|
-
}
|
|
76
|
-
const userConfig = await chunkNU3VTAH5_js.loadUserConfigFile(projectRoot, contextV2.workspaceRoot, resolver, "build", "development", configFile, framework);
|
|
77
|
-
if (!exists.existsSync(joinPaths.joinPaths(contextV2.workspaceRoot, projectRoot, "package.json"))) {
|
|
78
|
-
if (opts?.verbose) {
|
|
79
|
-
console.warn(`[${name}] - ${(/* @__PURE__ */ new Date()).toISOString()} - Cannot find \`package.json\` file in the project's root directory (path: "${joinPaths.joinPaths(contextV2.workspaceRoot, projectRoot)}"). Skipping project configuration.`);
|
|
80
|
-
}
|
|
81
|
-
return {};
|
|
82
|
-
}
|
|
83
|
-
const packageJsonContent = await promises.readFile(joinPaths.joinPaths(contextV2.workspaceRoot, projectRoot, "package.json"), "utf8");
|
|
84
|
-
if (!packageJsonContent) {
|
|
85
|
-
if (opts?.verbose) {
|
|
86
|
-
console.warn(`[${name}] - ${(/* @__PURE__ */ new Date()).toISOString()} - No package.json file found for project in root directory ${projectRoot}`);
|
|
87
|
-
}
|
|
88
|
-
return {};
|
|
89
|
-
}
|
|
90
|
-
const packageJson = JSON.parse(packageJsonContent);
|
|
91
|
-
if (!userConfig.configFile && !packageJson?.storm) {
|
|
92
|
-
if (opts?.verbose) {
|
|
93
|
-
console.debug(`[${name}] - ${(/* @__PURE__ */ new Date()).toISOString()} - Skipping ${projectRoot} - no ${framework} configuration found for project in root directory.`);
|
|
94
|
-
}
|
|
95
|
-
return {};
|
|
96
|
-
}
|
|
97
|
-
const projectConfig = pluginHelpers.getProjectConfigFromProjectRoot(projectRoot, packageJson);
|
|
98
|
-
if (!projectConfig) {
|
|
99
|
-
if (opts?.verbose) {
|
|
100
|
-
console.warn(`[${name}] - ${(/* @__PURE__ */ new Date()).toISOString()} - No project configuration found for project in root directory ${projectRoot}`);
|
|
101
|
-
}
|
|
102
|
-
return {};
|
|
103
|
-
}
|
|
104
|
-
const targets = packageJson_js.readTargetsFromPackageJson(packageJson, nxJson$1, projectRoot, context.workspaceRoot);
|
|
105
|
-
if (opts?.verbose) {
|
|
106
|
-
console.debug(`[${name}] - ${(/* @__PURE__ */ new Date()).toISOString()} - Preparing Nx targets for project in root directory ${projectRoot}.`);
|
|
107
|
-
}
|
|
108
|
-
if (options?.clean !== false && !targets[options?.clean?.targetName || "clean"]) {
|
|
109
|
-
targets[options?.clean?.targetName || "clean"] = {
|
|
110
|
-
cache: true,
|
|
111
|
-
inputs: Array.isArray(options?.clean?.inputs) ? options.clean.inputs : nxJson.withNamedInputs(targetInputs, [
|
|
112
|
-
options?.clean?.inputs || "typescript"
|
|
113
|
-
]),
|
|
114
|
-
outputs: options?.clean?.outputs,
|
|
115
|
-
executor: options?.clean?.executor || `@${framework}/nx:${options?.clean?.targetName || "clean"}`,
|
|
116
|
-
dependsOn: options?.clean?.dependsOn ?? [
|
|
117
|
-
`^${options?.clean?.targetName || "clean"}`
|
|
118
|
-
],
|
|
119
|
-
defaultConfiguration: options?.clean?.defaultConfiguration || "production",
|
|
120
|
-
options: {
|
|
121
|
-
outputPath: userConfig.output?.outputPath || "dist/{projectRoot}",
|
|
122
|
-
projectType: projectConfig.projectType || userConfig.type,
|
|
123
|
-
autoInstall: userConfig.autoInstall
|
|
124
|
-
},
|
|
125
|
-
configurations: {
|
|
126
|
-
production: {
|
|
127
|
-
mode: "production"
|
|
128
|
-
},
|
|
129
|
-
test: {
|
|
130
|
-
mode: "test"
|
|
131
|
-
},
|
|
132
|
-
development: {
|
|
133
|
-
mode: "development",
|
|
134
|
-
skipCache: true
|
|
135
|
-
}
|
|
136
|
-
}
|
|
137
|
-
};
|
|
138
|
-
}
|
|
139
|
-
if (options?.prepare !== false && !targets[options?.prepare?.targetName || "prepare"]) {
|
|
140
|
-
targets[options?.prepare?.targetName || "prepare"] = {
|
|
141
|
-
cache: true,
|
|
142
|
-
inputs: Array.isArray(options?.prepare?.inputs) ? options.prepare.inputs : nxJson.withNamedInputs(targetInputs, [
|
|
143
|
-
options?.prepare?.inputs || "typescript"
|
|
144
|
-
]),
|
|
145
|
-
outputs: options?.prepare?.outputs ?? [
|
|
146
|
-
artifactsFolder
|
|
147
|
-
],
|
|
148
|
-
executor: options?.prepare?.executor || `@${framework}/nx:${options?.prepare?.targetName || "prepare"}`,
|
|
149
|
-
dependsOn: options?.prepare?.dependsOn ?? [
|
|
150
|
-
`^${options?.prepare?.targetName || "build"}`,
|
|
151
|
-
options?.clean !== false && `${options?.clean?.targetName || "clean"}`
|
|
152
|
-
].filter(Boolean),
|
|
153
|
-
defaultConfiguration: options?.prepare?.defaultConfiguration || "production",
|
|
154
|
-
options: {
|
|
155
|
-
entry: userConfig.entry,
|
|
156
|
-
projectType: projectConfig.projectType || userConfig.type,
|
|
157
|
-
autoInstall: userConfig.autoInstall,
|
|
158
|
-
skipCache: userConfig.skipCache
|
|
159
|
-
},
|
|
160
|
-
configurations: {
|
|
161
|
-
production: {
|
|
162
|
-
mode: "production"
|
|
163
|
-
},
|
|
164
|
-
test: {
|
|
165
|
-
mode: "test"
|
|
166
|
-
},
|
|
167
|
-
development: {
|
|
168
|
-
mode: "development",
|
|
169
|
-
skipCache: true
|
|
170
|
-
}
|
|
171
|
-
}
|
|
172
|
-
};
|
|
173
|
-
}
|
|
174
|
-
if (options?.build !== false && !targets[options?.build?.targetName || "build"]) {
|
|
175
|
-
targets[options?.build?.targetName || "build"] = {
|
|
176
|
-
cache: true,
|
|
177
|
-
inputs: Array.isArray(options?.build?.inputs) ? options.build.inputs : nxJson.withNamedInputs(targetInputs, [
|
|
178
|
-
options?.build?.inputs || "typescript"
|
|
179
|
-
]),
|
|
180
|
-
outputs: options?.build?.outputs ?? [
|
|
181
|
-
"{options.outputPath}"
|
|
182
|
-
],
|
|
183
|
-
executor: options?.build?.executor || `@${framework}/nx:${options?.build?.targetName || "build"}`,
|
|
184
|
-
dependsOn: options?.build?.dependsOn ?? [
|
|
185
|
-
`^${options?.build?.targetName || "build"}`,
|
|
186
|
-
userConfig.skipCache ? void 0 : isSetObject.isSetObject(options?.prepare) && options?.prepare?.targetName ? options?.prepare?.targetName : "prepare"
|
|
187
|
-
].filter(Boolean),
|
|
188
|
-
defaultConfiguration: options?.build?.defaultConfiguration || "production",
|
|
189
|
-
options: {
|
|
190
|
-
entry: userConfig.entry,
|
|
191
|
-
outputPath: userConfig.output?.outputPath || "dist/{projectRoot}",
|
|
192
|
-
projectType: projectConfig.projectType || userConfig.type,
|
|
193
|
-
autoInstall: userConfig.autoInstall,
|
|
194
|
-
skipCache: userConfig.skipCache
|
|
195
|
-
},
|
|
196
|
-
configurations: {
|
|
197
|
-
production: {
|
|
198
|
-
mode: "production"
|
|
199
|
-
},
|
|
200
|
-
test: {
|
|
201
|
-
mode: "test"
|
|
202
|
-
},
|
|
203
|
-
development: {
|
|
204
|
-
mode: "development",
|
|
205
|
-
skipCache: true
|
|
206
|
-
}
|
|
207
|
-
}
|
|
208
|
-
};
|
|
209
|
-
}
|
|
210
|
-
if (options?.lint !== false && !targets[options?.lint?.targetName || "lint"]) {
|
|
211
|
-
targets[options?.lint?.targetName || "lint"] = {
|
|
212
|
-
cache: true,
|
|
213
|
-
inputs: Array.isArray(options?.lint?.inputs) ? options.lint.inputs : nxJson.withNamedInputs([
|
|
214
|
-
...targetInputs,
|
|
215
|
-
artifactsFolder
|
|
216
|
-
], options?.lint?.inputs ? [
|
|
217
|
-
options.lint.inputs
|
|
218
|
-
] : [
|
|
219
|
-
"linting",
|
|
220
|
-
"typescript"
|
|
221
|
-
]),
|
|
222
|
-
outputs: options?.lint?.outputs ?? [
|
|
223
|
-
"{options.outputPath}"
|
|
224
|
-
],
|
|
225
|
-
executor: options?.lint?.executor || `@${framework}/nx:${options?.lint?.targetName || "lint"}`,
|
|
226
|
-
dependsOn: options?.lint?.dependsOn ?? [
|
|
227
|
-
`^${options?.lint?.targetName || "lint"}`,
|
|
228
|
-
userConfig.skipCache ? void 0 : isSetObject.isSetObject(options?.prepare) && options?.prepare?.targetName ? options?.prepare?.targetName : "prepare"
|
|
229
|
-
].filter(Boolean),
|
|
230
|
-
defaultConfiguration: options?.lint?.defaultConfiguration || "production",
|
|
231
|
-
options: {
|
|
232
|
-
entry: userConfig.entry,
|
|
233
|
-
projectType: projectConfig.projectType || userConfig.type,
|
|
234
|
-
autoInstall: userConfig.autoInstall,
|
|
235
|
-
skipCache: userConfig.skipCache
|
|
236
|
-
},
|
|
237
|
-
configurations: {
|
|
238
|
-
production: {
|
|
239
|
-
mode: "production"
|
|
240
|
-
},
|
|
241
|
-
test: {
|
|
242
|
-
mode: "test"
|
|
243
|
-
},
|
|
244
|
-
development: {
|
|
245
|
-
mode: "development",
|
|
246
|
-
skipCache: true
|
|
247
|
-
}
|
|
248
|
-
}
|
|
249
|
-
};
|
|
250
|
-
}
|
|
251
|
-
if (options?.docs !== false && !targets[options?.docs?.targetName || "docs"]) {
|
|
252
|
-
targets[options?.docs?.targetName || "docs"] = {
|
|
253
|
-
cache: true,
|
|
254
|
-
inputs: Array.isArray(options?.docs?.inputs) ? options.docs.inputs : nxJson.withNamedInputs([
|
|
255
|
-
...targetInputs,
|
|
256
|
-
artifactsFolder
|
|
257
|
-
], options?.docs?.inputs ? [
|
|
258
|
-
options.docs.inputs
|
|
259
|
-
] : [
|
|
260
|
-
"documentation",
|
|
261
|
-
"typescript"
|
|
262
|
-
]),
|
|
263
|
-
outputs: options?.docs?.outputs ?? [
|
|
264
|
-
"{options.outputPath}"
|
|
265
|
-
],
|
|
266
|
-
executor: options?.docs?.executor || `@${framework}/nx:${options?.docs?.targetName || "docs"}`,
|
|
267
|
-
dependsOn: options?.docs?.dependsOn ?? [
|
|
268
|
-
`^${options?.docs?.targetName || "docs"}`,
|
|
269
|
-
options?.build !== false && `${options?.build?.targetName || "build"}`,
|
|
270
|
-
userConfig.skipCache ? void 0 : isSetObject.isSetObject(options?.prepare) && options?.prepare?.targetName ? options?.prepare?.targetName : "prepare"
|
|
271
|
-
].filter(Boolean),
|
|
272
|
-
defaultConfiguration: options?.docs?.defaultConfiguration || "production",
|
|
273
|
-
options: {
|
|
274
|
-
entry: userConfig.entry,
|
|
275
|
-
projectType: projectConfig.projectType || userConfig.type,
|
|
276
|
-
autoInstall: userConfig.autoInstall,
|
|
277
|
-
skipCache: userConfig.skipCache
|
|
278
|
-
},
|
|
279
|
-
configurations: {
|
|
280
|
-
production: {
|
|
281
|
-
mode: "production"
|
|
282
|
-
},
|
|
283
|
-
test: {
|
|
284
|
-
mode: "test"
|
|
285
|
-
},
|
|
286
|
-
development: {
|
|
287
|
-
mode: "development",
|
|
288
|
-
skipCache: true
|
|
289
|
-
}
|
|
290
|
-
}
|
|
291
|
-
};
|
|
292
|
-
}
|
|
293
|
-
if (options?.deploy !== false && !targets[options?.deploy?.targetName || "deploy"]) {
|
|
294
|
-
targets[options?.deploy?.targetName || "deploy"] = {
|
|
295
|
-
inputs: Array.isArray(options?.deploy?.inputs) ? options.deploy.inputs : nxJson.withNamedInputs([
|
|
296
|
-
...targetInputs,
|
|
297
|
-
artifactsFolder
|
|
298
|
-
], options?.deploy?.inputs ? [
|
|
299
|
-
options.deploy.inputs
|
|
300
|
-
] : [
|
|
301
|
-
"documentation",
|
|
302
|
-
"typescript"
|
|
303
|
-
]),
|
|
304
|
-
outputs: options?.deploy?.outputs ?? [
|
|
305
|
-
"{options.outputPath}"
|
|
306
|
-
],
|
|
307
|
-
executor: options?.deploy?.executor || `@${framework}/nx:${options?.deploy?.targetName || "deploy"}`,
|
|
308
|
-
dependsOn: options?.deploy?.dependsOn ?? [
|
|
309
|
-
`^${options?.deploy?.targetName || "deploy"}`,
|
|
310
|
-
options?.build !== false && `${options?.build?.targetName || "build"}`,
|
|
311
|
-
userConfig.skipCache ? void 0 : isSetObject.isSetObject(options?.prepare) && options?.prepare?.targetName ? options?.prepare?.targetName : "prepare"
|
|
312
|
-
].filter(Boolean),
|
|
313
|
-
defaultConfiguration: options?.deploy?.defaultConfiguration || "production",
|
|
314
|
-
options: {
|
|
315
|
-
entry: userConfig.entry,
|
|
316
|
-
projectType: projectConfig.projectType || userConfig.type,
|
|
317
|
-
autoInstall: userConfig.autoInstall,
|
|
318
|
-
skipCache: userConfig.skipCache
|
|
319
|
-
},
|
|
320
|
-
configurations: {
|
|
321
|
-
production: {
|
|
322
|
-
mode: "production"
|
|
323
|
-
},
|
|
324
|
-
test: {
|
|
325
|
-
mode: "test"
|
|
326
|
-
},
|
|
327
|
-
development: {
|
|
328
|
-
mode: "development",
|
|
329
|
-
skipCache: true
|
|
330
|
-
}
|
|
331
|
-
}
|
|
332
|
-
};
|
|
333
|
-
}
|
|
334
|
-
projectTags.setDefaultProjectTags(projectConfig, name);
|
|
335
|
-
projectTags.addProjectTag(projectConfig, framework, projectConfig.projectType || userConfig.type || "library", {
|
|
336
|
-
overwrite: true
|
|
337
|
-
});
|
|
338
|
-
if (opts?.verbose) {
|
|
339
|
-
console.debug(`[${name}] - ${(/* @__PURE__ */ new Date()).toISOString()} - Completed preparing Nx configuration for project in root directory ${projectRoot}.`);
|
|
340
|
-
}
|
|
341
|
-
return {
|
|
342
|
-
projects: {
|
|
343
|
-
[root]: defu__default.default(projectConfig, {
|
|
344
|
-
name: kebabCase.kebabCase(userConfig.name),
|
|
345
|
-
projectType: userConfig.type || "library",
|
|
346
|
-
root,
|
|
347
|
-
sourceRoot: joinPaths.joinPaths(root, "src"),
|
|
348
|
-
targets
|
|
349
|
-
})
|
|
350
|
-
}
|
|
351
|
-
};
|
|
352
|
-
} catch (error) {
|
|
353
|
-
console.error(`[${name}] - ${(/* @__PURE__ */ new Date()).toISOString()} - ${isError.isError(error) ? error.message : "Unknown fatal error"}`);
|
|
354
|
-
return {};
|
|
355
|
-
}
|
|
356
|
-
}, configFiles, options, contextV2);
|
|
357
|
-
}
|
|
358
|
-
];
|
|
359
|
-
}
|
|
360
|
-
chunkSHUYVCID_js.__name(createNxPlugin, "createNxPlugin");
|
|
361
|
-
|
|
362
|
-
exports.createNxPlugin = createNxPlugin;
|
|
363
|
-
exports.getNxPluginInputs = getNxPluginInputs;
|
|
364
|
-
exports.getNxTargetInputs = getNxTargetInputs;
|