@code-pushup/nx-plugin 0.51.0 → 0.53.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +47 -2
- package/executors.json +4 -4
- package/package.json +5 -5
- package/src/executors/{autorun → cli}/README.md +23 -7
- package/src/executors/{autorun → cli}/executor.d.ts +1 -8
- package/src/executors/{autorun → cli}/executor.js +10 -11
- package/src/executors/cli/executor.js.map +1 -0
- package/src/executors/cli/schema.js.map +1 -0
- package/src/executors/{autorun → cli}/schema.json +2 -4
- package/src/executors/cli/utils.js.map +1 -0
- package/src/executors/internal/cli.d.ts +4 -2
- package/src/executors/internal/cli.js +4 -4
- package/src/executors/internal/cli.js.map +1 -1
- package/src/executors/internal/config.js +1 -1
- package/src/executors/internal/config.js.map +1 -1
- package/src/executors/internal/types.d.ts +1 -0
- package/src/generators/configuration/README.md +12 -3
- package/src/generators/configuration/files/code-pushup.config.ts.template +1 -1
- package/src/generators/configuration/generator.js +1 -1
- package/src/generators/configuration/generator.js.map +1 -1
- package/src/generators/init/README.md +9 -1
- package/src/plugin/README.md +107 -0
- package/src/plugin/target/executor-target.js +1 -1
- package/src/plugin/target/executor-target.js.map +1 -1
- package/src/executors/autorun/constants.d.ts +0 -1
- package/src/executors/autorun/constants.js +0 -5
- package/src/executors/autorun/constants.js.map +0 -1
- package/src/executors/autorun/executor.js.map +0 -1
- package/src/executors/autorun/schema.js.map +0 -1
- package/src/executors/autorun/utils.js.map +0 -1
- /package/src/executors/{autorun → cli}/schema.d.ts +0 -0
- /package/src/executors/{autorun → cli}/schema.js +0 -0
- /package/src/executors/{autorun → cli}/utils.d.ts +0 -0
- /package/src/executors/{autorun → cli}/utils.js +0 -0
package/README.md
CHANGED
|
@@ -1,11 +1,30 @@
|
|
|
1
1
|
# @code-pushup/nx-plugin
|
|
2
2
|
|
|
3
|
+
### Plugin
|
|
4
|
+
|
|
5
|
+
Register this plugin in your `nx.json` to leverage a set of generators and executors to integrate Code PushUp into a Nx workspace.
|
|
6
|
+
|
|
7
|
+
#### Registration
|
|
8
|
+
|
|
9
|
+
```jsonc
|
|
10
|
+
// nx.json
|
|
11
|
+
{
|
|
12
|
+
//...
|
|
13
|
+
"plugins": ["@code-pushup/nx-plugin"]
|
|
14
|
+
}
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
Resulting targets:
|
|
18
|
+
|
|
19
|
+
- `nx run <project-name>:code-pushup--configuration` (no config file present)
|
|
20
|
+
- `nx run <project-name>:code-pushup` (`code-pushup.config.{ts,mjs,js}` is present)
|
|
21
|
+
|
|
3
22
|
### Generators
|
|
4
23
|
|
|
5
24
|
#### Init
|
|
6
25
|
|
|
7
26
|
Install JS packages and register plugin.
|
|
8
|
-
See [init docs](./src/generators/init/README.md) for details
|
|
27
|
+
See [init generator docs](./src/generators/init/README.md) for details
|
|
9
28
|
|
|
10
29
|
Examples:
|
|
11
30
|
|
|
@@ -15,9 +34,35 @@ Examples:
|
|
|
15
34
|
#### Configuration
|
|
16
35
|
|
|
17
36
|
Adds a `code-pushup` target to your `project.json`.
|
|
18
|
-
See [configuration docs](./src/generators/configuration/README.md) for details
|
|
37
|
+
See [configuration generator docs](./src/generators/configuration/README.md) for details
|
|
19
38
|
|
|
20
39
|
Examples:
|
|
21
40
|
|
|
22
41
|
- `nx g @code-pushup/nx-plugin:configuration --project=<project-name>`
|
|
23
42
|
- `nx g @code-pushup/nx-plugin:configuration --project=<project-name> --targetName=cp`
|
|
43
|
+
|
|
44
|
+
### Executor
|
|
45
|
+
|
|
46
|
+
#### CLI
|
|
47
|
+
|
|
48
|
+
Install JS packages configure a target in your project json.
|
|
49
|
+
See [CLI executor docs](./src/executor/cli/README.md) for details
|
|
50
|
+
|
|
51
|
+
Examples:
|
|
52
|
+
|
|
53
|
+
```json
|
|
54
|
+
{
|
|
55
|
+
"name": "my-project",
|
|
56
|
+
"targets": {
|
|
57
|
+
"code-pushup": {
|
|
58
|
+
"executor": "@code-pushup/nx-plugin:cli",
|
|
59
|
+
"options": {
|
|
60
|
+
"projectPrefix": "workspace-name"
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
- `nx run <project-name>:code-pushup`
|
|
68
|
+
- `nx run <project-name>:code-pushup print-config --persist.filename=custom-report`
|
package/executors.json
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
{
|
|
2
2
|
"executors": {
|
|
3
|
-
"
|
|
4
|
-
"implementation": "./src/executors/
|
|
5
|
-
"schema": "./src/executors/
|
|
6
|
-
"description": "CodePushup CLI
|
|
3
|
+
"cli": {
|
|
4
|
+
"implementation": "./src/executors/cli/executor",
|
|
5
|
+
"schema": "./src/executors/cli/schema.json",
|
|
6
|
+
"description": "CodePushup CLI executor. Executes the @code-pushup/cli command's See: https://github.com/code-pushup/cli/blob/main/packages/cli/README.md#commands"
|
|
7
7
|
}
|
|
8
8
|
}
|
|
9
9
|
}
|
package/package.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@code-pushup/nx-plugin",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.53.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "Nx plugin to integrate the Code PushUp CLI into your workspace 🛠️",
|
|
6
|
-
"homepage": "code-pushup.dev",
|
|
7
6
|
"publishConfig": {
|
|
8
7
|
"access": "public"
|
|
9
8
|
},
|
|
9
|
+
"homepage": "code-pushup.dev",
|
|
10
10
|
"bugs": {
|
|
11
11
|
"url": "https://github.com/code-pushup/cli/issues"
|
|
12
12
|
},
|
|
@@ -17,11 +17,11 @@
|
|
|
17
17
|
},
|
|
18
18
|
"dependencies": {
|
|
19
19
|
"@nx/devkit": "^17.1.3",
|
|
20
|
-
"tslib": "
|
|
20
|
+
"tslib": "2.6.3",
|
|
21
21
|
"nx": "^17.1.3",
|
|
22
|
-
"@code-pushup/models": "0.
|
|
22
|
+
"@code-pushup/models": "0.53.0",
|
|
23
23
|
"zod": "^3.22.4",
|
|
24
|
-
"@code-pushup/utils": "0.
|
|
24
|
+
"@code-pushup/utils": "0.53.0"
|
|
25
25
|
},
|
|
26
26
|
"type": "commonjs",
|
|
27
27
|
"main": "./src/index.js",
|
|
@@ -1,25 +1,41 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Command Executor
|
|
2
2
|
|
|
3
|
-
This executor is used to run the
|
|
4
|
-
For details on the CLI command read the [CLI
|
|
3
|
+
This executor is used to run the Code PushUp CLI in an Nx workspace.
|
|
4
|
+
For details on the CLI command read the [CLI commands documentation](https://github.com/code-pushup/cli/blob/main/packages/cli/README.md#commands).
|
|
5
5
|
|
|
6
|
-
#### @code-pushup/nx-plugin:
|
|
6
|
+
#### @code-pushup/nx-plugin:cli
|
|
7
7
|
|
|
8
8
|
## Usage
|
|
9
9
|
|
|
10
|
-
|
|
10
|
+
Configure a target in your project json.
|
|
11
11
|
|
|
12
|
-
```
|
|
12
|
+
```jsonc
|
|
13
|
+
// <project-name>/project.json
|
|
13
14
|
{
|
|
14
15
|
"name": "my-project",
|
|
15
16
|
"targets": {
|
|
16
17
|
"code-pushup": {
|
|
17
|
-
"executor": "@code-pushup/nx-plugin:
|
|
18
|
+
"executor": "@code-pushup/nx-plugin:cli"
|
|
18
19
|
}
|
|
19
20
|
}
|
|
20
21
|
}
|
|
21
22
|
```
|
|
22
23
|
|
|
24
|
+
Run
|
|
25
|
+
`nx run <project-name>:code-pushup`
|
|
26
|
+
|
|
27
|
+
```text
|
|
28
|
+
Root/
|
|
29
|
+
├── .code-pushup/
|
|
30
|
+
│ ├── report.json 👈 generated
|
|
31
|
+
│ └── report.md 👈 generated
|
|
32
|
+
├── project-name/
|
|
33
|
+
│ ├── project.json
|
|
34
|
+
│ ├── code-pushup.config.ts 👈 executed
|
|
35
|
+
│ └── ...
|
|
36
|
+
└── ...
|
|
37
|
+
```
|
|
38
|
+
|
|
23
39
|
By default, the Nx plugin will derive the options from the executor config.
|
|
24
40
|
|
|
25
41
|
The following things happen:
|
|
@@ -5,11 +5,4 @@ export type ExecutorOutput = {
|
|
|
5
5
|
command?: string;
|
|
6
6
|
error?: Error;
|
|
7
7
|
};
|
|
8
|
-
export default function runAutorunExecutor(terminalAndExecutorOptions: AutorunCommandExecutorOptions, context: ExecutorContext): Promise<
|
|
9
|
-
success: boolean;
|
|
10
|
-
command: string;
|
|
11
|
-
error: unknown;
|
|
12
|
-
}> | Promise<{
|
|
13
|
-
success: true;
|
|
14
|
-
command: string;
|
|
15
|
-
}>;
|
|
8
|
+
export default function runAutorunExecutor(terminalAndExecutorOptions: AutorunCommandExecutorOptions, context: ExecutorContext): Promise<ExecutorOutput>;
|
|
@@ -5,39 +5,38 @@ const devkit_1 = require("@nx/devkit");
|
|
|
5
5
|
const node_child_process_1 = require("node:child_process");
|
|
6
6
|
const cli_1 = require("../internal/cli");
|
|
7
7
|
const context_1 = require("../internal/context");
|
|
8
|
-
const constants_1 = require("./constants");
|
|
9
8
|
const utils_1 = require("./utils");
|
|
10
9
|
function runAutorunExecutor(terminalAndExecutorOptions, context) {
|
|
11
10
|
const normalizedContext = (0, context_1.normalizeContext)(context);
|
|
12
11
|
const cliArgumentObject = (0, utils_1.parseAutorunExecutorOptions)(terminalAndExecutorOptions, normalizedContext);
|
|
13
|
-
const { dryRun, verbose } = terminalAndExecutorOptions;
|
|
14
|
-
const
|
|
15
|
-
const
|
|
12
|
+
const { dryRun, verbose, command } = terminalAndExecutorOptions;
|
|
13
|
+
const commandString = (0, cli_1.createCliCommand)({ command, args: cliArgumentObject });
|
|
14
|
+
const commandStringOptions = context.cwd ? { cwd: context.cwd } : {};
|
|
16
15
|
if (verbose) {
|
|
17
|
-
devkit_1.logger.info(`Run ${
|
|
18
|
-
devkit_1.logger.info(`Command: ${
|
|
16
|
+
devkit_1.logger.info(`Run CLI executor ${command ?? ''}`);
|
|
17
|
+
devkit_1.logger.info(`Command: ${commandString}`);
|
|
19
18
|
}
|
|
20
19
|
if (dryRun) {
|
|
21
|
-
devkit_1.logger.warn(`DryRun execution of: ${
|
|
20
|
+
devkit_1.logger.warn(`DryRun execution of: ${commandString}`);
|
|
22
21
|
}
|
|
23
22
|
else {
|
|
24
23
|
try {
|
|
25
24
|
// @TODO use executeProcess instead of execSync -> non blocking, logs #761
|
|
26
25
|
// eslint-disable-next-line n/no-sync
|
|
27
|
-
(0, node_child_process_1.execSync)(
|
|
26
|
+
(0, node_child_process_1.execSync)(commandString, commandStringOptions);
|
|
28
27
|
}
|
|
29
28
|
catch (error) {
|
|
30
29
|
devkit_1.logger.error(error);
|
|
31
30
|
return Promise.resolve({
|
|
32
31
|
success: false,
|
|
33
|
-
command,
|
|
34
|
-
error,
|
|
32
|
+
command: commandString,
|
|
33
|
+
error: error,
|
|
35
34
|
});
|
|
36
35
|
}
|
|
37
36
|
}
|
|
38
37
|
return Promise.resolve({
|
|
39
38
|
success: true,
|
|
40
|
-
command,
|
|
39
|
+
command: commandString,
|
|
41
40
|
});
|
|
42
41
|
}
|
|
43
42
|
exports.default = runAutorunExecutor;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"executor.js","sourceRoot":"","sources":["../../../../../../packages/nx-plugin/src/executors/cli/executor.ts"],"names":[],"mappings":";;AAAA,uCAA0D;AAC1D,qCAAqC;AACrC,2DAA8C;AAC9C,yCAAmD;AACnD,iDAAuD;AAEvD,mCAAsD;AAQtD,SAAwB,kBAAkB,CACxC,0BAAyD,EACzD,OAAwB;IAExB,MAAM,iBAAiB,GAAG,IAAA,0BAAgB,EAAC,OAAO,CAAC,CAAC;IACpD,MAAM,iBAAiB,GAAG,IAAA,mCAA2B,EACnD,0BAA0B,EAC1B,iBAAiB,CAClB,CAAC;IACF,MAAM,EAAE,MAAM,EAAE,OAAO,EAAE,OAAO,EAAE,GAAG,0BAA0B,CAAC;IAEhE,MAAM,aAAa,GAAG,IAAA,sBAAgB,EAAC,EAAE,OAAO,EAAE,IAAI,EAAE,iBAAiB,EAAE,CAAC,CAAC;IAC7E,MAAM,oBAAoB,GAAG,OAAO,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,GAAG,EAAE,OAAO,CAAC,GAAG,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;IACrE,IAAI,OAAO,EAAE,CAAC;QACZ,eAAM,CAAC,IAAI,CAAC,oBAAoB,OAAO,IAAI,EAAE,EAAE,CAAC,CAAC;QACjD,eAAM,CAAC,IAAI,CAAC,YAAY,aAAa,EAAE,CAAC,CAAC;IAC3C,CAAC;IACD,IAAI,MAAM,EAAE,CAAC;QACX,eAAM,CAAC,IAAI,CAAC,wBAAwB,aAAa,EAAE,CAAC,CAAC;IACvD,CAAC;SAAM,CAAC;QACN,IAAI,CAAC;YACH,0EAA0E;YAC1E,qCAAqC;YACrC,IAAA,6BAAQ,EAAC,aAAa,EAAE,oBAAoB,CAAC,CAAC;QAChD,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,eAAM,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;YACpB,OAAO,OAAO,CAAC,OAAO,CAAC;gBACrB,OAAO,EAAE,KAAK;gBACd,OAAO,EAAE,aAAa;gBACtB,KAAK,EAAE,KAAc;aACtB,CAAC,CAAC;QACL,CAAC;IACH,CAAC;IAED,OAAO,OAAO,CAAC,OAAO,CAAC;QACrB,OAAO,EAAE,IAAI;QACb,OAAO,EAAE,aAAa;KACvB,CAAC,CAAC;AACL,CAAC;AAtCD,qCAsCC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"schema.js","sourceRoot":"","sources":["../../../../../../packages/nx-plugin/src/executors/cli/schema.ts"],"names":[],"mappings":""}
|
|
@@ -5,11 +5,9 @@
|
|
|
5
5
|
"description": "Executes the @code-pushup/cli autorun command See: https://github.com/code-pushup/cli/blob/main/packages/cli/README.md#autorun-command",
|
|
6
6
|
"type": "object",
|
|
7
7
|
"properties": {
|
|
8
|
-
"
|
|
8
|
+
"command": {
|
|
9
9
|
"type": "string",
|
|
10
|
-
"description": "The
|
|
11
|
-
"x-prompt": "Which project should configure Code Pushup?",
|
|
12
|
-
"x-dropdown": "projects",
|
|
10
|
+
"description": "The command to run.",
|
|
13
11
|
"$default": {
|
|
14
12
|
"$source": "argv",
|
|
15
13
|
"index": 0
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"utils.js","sourceRoot":"","sources":["../../../../../../packages/nx-plugin/src/executors/cli/utils.ts"],"names":[],"mappings":";;;AAAA,+CAA+E;AAO/E,SAAgB,+BAA+B,CAC7C,OAAmD;IAEnD,MAAM,EAAE,aAAa,EAAE,MAAM,EAAE,WAAW,EAAE,GAAG,OAAO,CAAC;IACvD,OAAO;QACL,GAAG,CAAC,aAAa,IAAI,EAAE,aAAa,EAAE,CAAC;QACvC,GAAG,CAAC,MAAM,IAAI,IAAI,IAAI,EAAE,MAAM,EAAE,CAAC;QACjC,GAAG,CAAC,WAAW,IAAI,EAAE,WAAW,EAAE,CAAC;KACpC,CAAC;AACJ,CAAC;AATD,0EASC;AAED,SAAgB,2BAA2B,CACzC,OAA+C,EAC/C,iBAA4C;IAE5C,MAAM,EAAE,aAAa,EAAE,OAAO,EAAE,MAAM,EAAE,GAAG,OAAO,CAAC;IACnD,OAAO;QACL,GAAG,+BAA+B,CAAC,OAAO,CAAC;QAC3C,GAAG,IAAA,qBAAY,EAAC,OAAO,EAAE,iBAAiB,CAAC;QAC3C,OAAO,EAAE,IAAA,sBAAa,EAAC,EAAE,aAAa,EAAE,GAAG,OAAO,EAAE,EAAE,iBAAiB,CAAC;QACxE,MAAM,EAAE,IAAA,qBAAY,EAAC,EAAE,aAAa,EAAE,GAAG,MAAM,EAAE,EAAE,iBAAiB,CAAC;KACtE,CAAC;AACJ,CAAC;AAXD,kEAWC"}
|
|
@@ -1,5 +1,7 @@
|
|
|
1
|
-
export declare function createCliCommand(
|
|
2
|
-
|
|
1
|
+
export declare function createCliCommand(options?: {
|
|
2
|
+
args?: Record<string, unknown>;
|
|
3
|
+
command?: string;
|
|
4
|
+
bin?: string;
|
|
3
5
|
}): string;
|
|
4
6
|
type ArgumentValue = number | string | boolean | string[];
|
|
5
7
|
export type CliArgsObject<T extends object = Record<string, ArgumentValue>> = T extends never ? // eslint-disable-next-line @typescript-eslint/naming-convention
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.objectToCliArgs = exports.createCliCommand = void 0;
|
|
4
|
-
function createCliCommand(
|
|
5
|
-
const { bin = '@code-pushup/cli' } = options ?? {};
|
|
6
|
-
return `npx ${bin} ${command
|
|
4
|
+
function createCliCommand(options) {
|
|
5
|
+
const { bin = '@code-pushup/cli', command, args } = options ?? {};
|
|
6
|
+
return `npx ${bin} ${objectToCliArgs({ _: command ?? [], ...args }).join(' ')}`;
|
|
7
7
|
}
|
|
8
8
|
exports.createCliCommand = createCliCommand;
|
|
9
9
|
// @TODO import from @code-pushup/utils => get rid of poppins for cjs support
|
|
@@ -17,7 +17,7 @@ function objectToCliArgs(params) {
|
|
|
17
17
|
// process/file/script
|
|
18
18
|
if (key === '_') {
|
|
19
19
|
// eslint-disable-next-line @typescript-eslint/no-unsafe-return
|
|
20
|
-
return Array.isArray(value) ? value : [`${value}`];
|
|
20
|
+
return (Array.isArray(value) ? value : [`${value}`]).filter(v => v != null);
|
|
21
21
|
}
|
|
22
22
|
const prefix = key.length === 1 ? '-' : '--';
|
|
23
23
|
// "-*" arguments (shorthands)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cli.js","sourceRoot":"","sources":["../../../../../../packages/nx-plugin/src/executors/internal/cli.ts"],"names":[],"mappings":";;;AAAA,SAAgB,gBAAgB,
|
|
1
|
+
{"version":3,"file":"cli.js","sourceRoot":"","sources":["../../../../../../packages/nx-plugin/src/executors/internal/cli.ts"],"names":[],"mappings":";;;AAAA,SAAgB,gBAA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C,KAAgC,CAAC,CAAC,OAAO;YAC7D,4DAA4D;YAC5D,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,eAAe,CAAC,EAAE,CAAC,GAAG,GAAG,IAAI,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,CACpD,CAAC;QACJ,CAAC;QAED,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE,CAAC;YAC9B,OAAO,CAAC,GAAG,MAAM,GAAG,GAAG,KAAK,KAAK,GAAG,CAAC,CAAC;QACxC,CAAC;QAED,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE,CAAC;YAC9B,OAAO,CAAC,GAAG,MAAM,GAAG,GAAG,IAAI,KAAK,EAAE,CAAC,CAAC;QACtC,CAAC;QAED,IAAI,OAAO,KAAK,KAAK,SAAS,EAAE,CAAC;YAC/B,OAAO,CAAC,GAAG,MAAM,GAAG,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,KAAK,GAAG,GAAG,EAAE,CAAC,CAAC;QAClD,CAAC;QAED,IAAI,KAAK,KAAK,SAAS,EAAE,CAAC;YACxB,OAAO,EAAE,CAAC;QACZ,CAAC;QAED,MAAM,IAAI,KAAK,CAAC,oBAAoB,OAAO,KAAK,YAAY,GAAG,EAAE,CAAC,CAAC;IACrE,CAAC,CAAC,CAAC;AACL,CAAC;AAhDD,0CAgDC"}
|
|
@@ -36,7 +36,7 @@ function uploadConfig(options, context) {
|
|
|
36
36
|
return {
|
|
37
37
|
...(projectName
|
|
38
38
|
? {
|
|
39
|
-
project: applyPrefix ? `${prefix}${projectName}` : projectName,
|
|
39
|
+
project: applyPrefix ? `${prefix}${projectName}` : projectName,
|
|
40
40
|
}
|
|
41
41
|
: {}),
|
|
42
42
|
...(0, env_1.parseEnv)(process.env),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config.js","sourceRoot":"","sources":["../../../../../../packages/nx-plugin/src/executors/internal/config.ts"],"names":[],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AAC,CAAC,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,KAAK,SAAS,CAC5B,CACF;KACF,CAAC;AACJ,CAAC;AAxBD,oCAwBC"}
|
|
@@ -17,6 +17,7 @@ export type ProjectExecutorOnlyOptions = {
|
|
|
17
17
|
* CLI types that apply globally for all commands.
|
|
18
18
|
*/
|
|
19
19
|
export type GlobalExecutorOptions = {
|
|
20
|
+
command?: 'collect' | 'upload' | 'autorun' | 'print-config' | 'compare' | 'merge-diffs' | 'history';
|
|
20
21
|
bin?: string;
|
|
21
22
|
verbose?: boolean;
|
|
22
23
|
progress?: boolean;
|
|
@@ -4,13 +4,22 @@
|
|
|
4
4
|
|
|
5
5
|
## Usage
|
|
6
6
|
|
|
7
|
-
`nx generate configuration
|
|
7
|
+
`nx generate @code-pushup/nx-plugin:configuration`
|
|
8
8
|
|
|
9
9
|
By default, the Nx plugin will search for existing configuration files. If they are not present it creates a `code-pushup.config.ts` and adds a target to your `project.json` file.
|
|
10
10
|
|
|
11
|
-
You can specify the
|
|
11
|
+
You can specify the project explicitly as follows:
|
|
12
12
|
|
|
13
|
-
`nx g @code-pushup/nx-plugin:configuration
|
|
13
|
+
`nx g @code-pushup/nx-plugin:configuration <project-name>`
|
|
14
|
+
|
|
15
|
+
```text
|
|
16
|
+
Root/
|
|
17
|
+
├── project-name/
|
|
18
|
+
│ ├── project.json 👈 updated
|
|
19
|
+
│ ├── code-pushup.config.ts 👈 generated
|
|
20
|
+
│ └── ...
|
|
21
|
+
└── ...
|
|
22
|
+
```
|
|
14
23
|
|
|
15
24
|
Show what will be generated without writing to disk:
|
|
16
25
|
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
// see: https://github.com/code-pushup/cli/blob/main/packages/models/docs/models-reference.md#coreconfig
|
|
4
4
|
export default {
|
|
5
5
|
<% if (persist) { %>persist: <%- persist %>,<% } %>
|
|
6
|
-
<% if (upload) { %>
|
|
6
|
+
<% if (upload) { %>upload: <%- upload %>,<% } %>
|
|
7
7
|
<% if (plugins) { %>plugins: <%- plugins %>,<% } %>
|
|
8
8
|
<% if (categories) { %>categories: <%- categories %><% } %>
|
|
9
9
|
} satisfies CoreConfig;
|
|
@@ -31,7 +31,7 @@ function addTargetToProject(tree, projectConfiguration, options) {
|
|
|
31
31
|
const { targets } = projectConfiguration;
|
|
32
32
|
const { targetName, project } = options;
|
|
33
33
|
const codePushupTargetConfig = {
|
|
34
|
-
executor: `${constants_1.PACKAGE_NAME}:
|
|
34
|
+
executor: `${constants_1.PACKAGE_NAME}:cli`,
|
|
35
35
|
};
|
|
36
36
|
(0, devkit_1.updateProjectConfiguration)(tree, project, {
|
|
37
37
|
...projectConfiguration,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"generator.js","sourceRoot":"","sources":["../../../../../../packages/nx-plugin/src/generators/configuration/generator.ts"],"names":[],"mappings":";;;AAAA,uCAMoB;AAEpB,wDAA6E;AAC7E,6DAAgE;AAGzD,KAAK,UAAU,sBAAsB,CAC1C,IAAU,EACV,OAAsC;IAEtC,MAAM,oBAAoB,GAAG,IAAA,iCAAwB,EAAC,IAAI,EAAE,OAAO,CAAC,OAAO,CAAC,CAAC;IAE7E,MAAM,EAAE,UAAU,EAAE,UAAU,EAAE,UAAU,EAAE,GAAG,OAAO,CAAC;IAEvD,IAAI,UAAU,KAAK,IAAI,EAAE,CAAC;QACxB,eAAM,CAAC,IAAI,CAAC,2BAA2B,CAAC,CAAC;IAC3C,CAAC;SAAM,CAAC;QACN,IAAA,6CAAwB,EAAC,IAAI,EAAE,oBAAoB,CAAC,IAAI,CAAC,CAAC;IAC5D,CAAC;IAED,IAAI,UAAU,KAAK,IAAI,EAAE,CAAC;QACxB,eAAM,CAAC,IAAI,CAAC,+BAA+B,CAAC,CAAC;IAC/C,CAAC;SAAM,CAAC;QACN,kBAAkB,CAAC,IAAI,EAAE,oBAAoB,EAAE,OAAO,CAAC,CAAC;IAC1D,CAAC;IAED,IAAI,UAAU,KAAK,IAAI,EAAE,CAAC;QACxB,eAAM,CAAC,IAAI,CAAC,uBAAuB,CAAC,CAAC;IACvC,CAAC;SAAM,CAAC;QACN,MAAM,IAAA,oBAAW,EAAC,IAAI,CAAC,CAAC;IAC1B,CAAC;AACH,CAAC;AAzBD,wDAyBC;AAED,SAAgB,kBAAkB,CAChC,IAAU,EACV,oBAA0C,EAC1C,OAAsC;IAEtC,MAAM,EAAE,OAAO,EAAE,GAAG,oBAAoB,CAAC;IACzC,MAAM,EAAE,UAAU,EAAE,OAAO,EAAE,GAAG,OAAO,CAAC;IAExC,MAAM,sBAAsB,GAAG;QAC7B,QAAQ,EAAE,GAAG,wBAAY,
|
|
1
|
+
{"version":3,"file":"generator.js","sourceRoot":"","sources":["../../../../../../packages/nx-plugin/src/generators/configuration/generator.ts"],"names":[],"mappings":";;;AAAA,uCAMoB;AAEpB,wDAA6E;AAC7E,6DAAgE;AAGzD,KAAK,UAAU,sBAAsB,CAC1C,IAAU,EACV,OAAsC;IAEtC,MAAM,oBAAoB,GAAG,IAAA,iCAAwB,EAAC,IAAI,EAAE,OAAO,CAAC,OAAO,CAAC,CAAC;IAE7E,MAAM,EAAE,UAAU,EAAE,UAAU,EAAE,UAAU,EAAE,GAAG,OAAO,CAAC;IAEvD,IAAI,UAAU,KAAK,IAAI,EAAE,CAAC;QACxB,eAAM,CAAC,IAAI,CAAC,2BAA2B,CAAC,CAAC;IAC3C,CAAC;SAAM,CAAC;QACN,IAAA,6CAAwB,EAAC,IAAI,EAAE,oBAAoB,CAAC,IAAI,CAAC,CAAC;IAC5D,CAAC;IAED,IAAI,UAAU,KAAK,IAAI,EAAE,CAAC;QACxB,eAAM,CAAC,IAAI,CAAC,+BAA+B,CAAC,CAAC;IAC/C,CAAC;SAAM,CAAC;QACN,kBAAkB,CAAC,IAAI,EAAE,oBAAoB,EAAE,OAAO,CAAC,CAAC;IAC1D,CAAC;IAED,IAAI,UAAU,KAAK,IAAI,EAAE,CAAC;QACxB,eAAM,CAAC,IAAI,CAAC,uBAAuB,CAAC,CAAC;IACvC,CAAC;SAAM,CAAC;QACN,MAAM,IAAA,oBAAW,EAAC,IAAI,CAAC,CAAC;IAC1B,CAAC;AACH,CAAC;AAzBD,wDAyBC;AAED,SAAgB,kBAAkB,CAChC,IAAU,EACV,oBAA0C,EAC1C,OAAsC;IAEtC,MAAM,EAAE,OAAO,EAAE,GAAG,oBAAoB,CAAC;IACzC,MAAM,EAAE,UAAU,EAAE,OAAO,EAAE,GAAG,OAAO,CAAC;IAExC,MAAM,sBAAsB,GAAG;QAC7B,QAAQ,EAAE,GAAG,wBAAY,MAAM;KAChC,CAAC;IAEF,IAAA,mCAA0B,EAAC,IAAI,EAAE,OAAO,EAAE;QACxC,GAAG,oBAAoB;QACvB,OAAO,EAAE;YACP,GAAG,OAAO;YACV,CAAC,UAAU,IAAI,+BAAmB,CAAC,EAAE,sBAAsB;SAC5D;KACF,CAAC,CAAC;AACL,CAAC;AAnBD,gDAmBC;AAED,kBAAe,sBAAsB,CAAC"}
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
## Usage
|
|
6
6
|
|
|
7
|
-
`nx generate
|
|
7
|
+
`nx generate @code-pushup/nx-plugin:init`
|
|
8
8
|
|
|
9
9
|
By default, the Nx plugin will update your `package.json` with needed dependencies and register the plugin in your `nx.json` configuration.
|
|
10
10
|
|
|
@@ -12,6 +12,14 @@ You can specify the collection explicitly as follows:
|
|
|
12
12
|
|
|
13
13
|
`nx g @code-pushup/nx-plugin:init`
|
|
14
14
|
|
|
15
|
+
```text
|
|
16
|
+
Root/
|
|
17
|
+
├── ...
|
|
18
|
+
├── nx.json 👈 updated
|
|
19
|
+
├── package.json 👈 updated
|
|
20
|
+
└── ...
|
|
21
|
+
```
|
|
22
|
+
|
|
15
23
|
Show what will be generated without writing to disk:
|
|
16
24
|
|
|
17
25
|
`nx g @code-pushup/nx-plugin:init --dry-run`
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
# @code-pushup/nx-plugin
|
|
2
|
+
|
|
3
|
+
The Nx Plugin for [Code PushUp](https://github.com/code-pushup/cli#readme), an open source code quality and conformance tool.
|
|
4
|
+
|
|
5
|
+
Why should you use this plugin?
|
|
6
|
+
|
|
7
|
+
- Zero setup cost. Just run the `init` generator and you're good to go.
|
|
8
|
+
- Smoother CI integration
|
|
9
|
+
- Minimal configuration
|
|
10
|
+
- Automated setup, migration and maintenance
|
|
11
|
+
|
|
12
|
+
## Usage
|
|
13
|
+
|
|
14
|
+
```jsonc
|
|
15
|
+
// nx.json
|
|
16
|
+
{
|
|
17
|
+
//...
|
|
18
|
+
"plugins": ["@code-pushup/nx-plugin"]
|
|
19
|
+
}
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
or with options:
|
|
23
|
+
|
|
24
|
+
```jsonc
|
|
25
|
+
// nx.json
|
|
26
|
+
{
|
|
27
|
+
//...
|
|
28
|
+
"plugins": [
|
|
29
|
+
{
|
|
30
|
+
"plugin": "@code-pushup/nx-plugin",
|
|
31
|
+
"options": {
|
|
32
|
+
"projectPrefix": "cli"
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
]
|
|
36
|
+
}
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
Now every project will have `code-pushup--configuration` target if no `code-pushup.{ts,mjs,js}` is present.
|
|
40
|
+
|
|
41
|
+
- `nx run <project-name>:code-pushup--configuration`
|
|
42
|
+
- `nx run <project-name>:code-pushup--configuration --skipFormat`
|
|
43
|
+
|
|
44
|
+
Run it and the project will get automatically configured.
|
|
45
|
+
|
|
46
|
+
```text
|
|
47
|
+
Root/
|
|
48
|
+
├── project-name/
|
|
49
|
+
│ ├── code-pushup.config.ts 👈 generated
|
|
50
|
+
│ └── ...
|
|
51
|
+
└── ...
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
For details visit the [configuration generator docs](../generators/configuration/README.md).
|
|
55
|
+
|
|
56
|
+
With the configuration from above a `code-pushup` target is now present.
|
|
57
|
+
|
|
58
|
+
- `nx run <project-name>:code-pushup`
|
|
59
|
+
|
|
60
|
+
Run it and the project will get automatically collect the report.
|
|
61
|
+
|
|
62
|
+
```text
|
|
63
|
+
Root/
|
|
64
|
+
├── .code-pushup/
|
|
65
|
+
│ └── project-name
|
|
66
|
+
│ ├── report.md 👈 generated
|
|
67
|
+
│ └── report.json 👈 generated
|
|
68
|
+
├── project-name/
|
|
69
|
+
│ ├── code-pushup.config.ts
|
|
70
|
+
│ └── ...
|
|
71
|
+
└── ...
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
Pass positional arguments to execute a specific command, use named arguments to overwrite defaults.
|
|
75
|
+
|
|
76
|
+
- `nx run <project-name>:code-pushup --onlyPlugins=eslint`
|
|
77
|
+
- `nx run <project-name>:code-pushup collect`
|
|
78
|
+
- `nx run <project-name>:code-pushup upload --upload.server=https://staging.code-pushup.dev`
|
|
79
|
+
|
|
80
|
+
For a full list of command visit the [Code PushUp CLI documentation](../../../cli/README.md#commands).
|
|
81
|
+
|
|
82
|
+
## Options
|
|
83
|
+
|
|
84
|
+
| Name | type | description |
|
|
85
|
+
| ----------------- | -------------------------------- | ------------------------------------------------------ |
|
|
86
|
+
| **projectPrefix** | `string` | prefix for upload.project on non root projects |
|
|
87
|
+
| **targetName** | `string` (DEFAULT 'code-pushup') | The id used to identify a target in your project.json. |
|
|
88
|
+
| **bin** | `string` | Path to Code PushUp CLI |
|
|
89
|
+
|
|
90
|
+
All options are optional and provided in the `nx.json` file.
|
|
91
|
+
|
|
92
|
+
```jsonc
|
|
93
|
+
// nx.json
|
|
94
|
+
{
|
|
95
|
+
//...
|
|
96
|
+
"plugins": [
|
|
97
|
+
{
|
|
98
|
+
"plugin": "@code-pushup/nx-plugin",
|
|
99
|
+
"options": {
|
|
100
|
+
"projectPrefix": "cli"
|
|
101
|
+
"targetName": "cp"
|
|
102
|
+
"bin": "dist/package/code-pushup-custom-build"
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
]
|
|
106
|
+
}
|
|
107
|
+
```
|
|
@@ -5,7 +5,7 @@ const constants_1 = require("../../internal/constants");
|
|
|
5
5
|
function createExecutorTarget(options) {
|
|
6
6
|
const { bin = constants_1.PACKAGE_NAME, projectPrefix } = options ?? {};
|
|
7
7
|
return {
|
|
8
|
-
executor: `${bin}:
|
|
8
|
+
executor: `${bin}:cli`,
|
|
9
9
|
...(projectPrefix
|
|
10
10
|
? {
|
|
11
11
|
options: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"executor-target.js","sourceRoot":"","sources":["../../../../../../packages/nx-plugin/src/plugin/target/executor-target.ts"],"names":[],"mappings":";;;AACA,wDAAwD;AAGxD,SAAgB,oBAAoB,CAAC,OAGpC;IACC,MAAM,EAAE,GAAG,GAAG,wBAAY,EAAE,aAAa,EAAE,GAAG,OAAO,IAAI,EAAE,CAAC;IAC5D,OAAO;QACL,QAAQ,EAAE,GAAG,GAAG,
|
|
1
|
+
{"version":3,"file":"executor-target.js","sourceRoot":"","sources":["../../../../../../packages/nx-plugin/src/plugin/target/executor-target.ts"],"names":[],"mappings":";;;AACA,wDAAwD;AAGxD,SAAgB,oBAAoB,CAAC,OAGpC;IACC,MAAM,EAAE,GAAG,GAAG,wBAAY,EAAE,aAAa,EAAE,GAAG,OAAO,IAAI,EAAE,CAAC;IAC5D,OAAO;QACL,QAAQ,EAAE,GAAG,GAAG,MAAM;QACtB,GAAG,CAAC,aAAa;YACf,CAAC,CAAC;gBACE,OAAO,EAAE;oBACP,aAAa;iBACd;aACF;YACH,CAAC,CAAC,EAAE,CAAC;KACR,CAAC;AACJ,CAAC;AAfD,oDAeC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare const AUTORUN_COMMAND = "autorun";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../../../../../../packages/nx-plugin/src/executors/autorun/constants.ts"],"names":[],"mappings":";;;AAAa,QAAA,eAAe,GAAG,SAAS,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"executor.js","sourceRoot":"","sources":["../../../../../../packages/nx-plugin/src/executors/autorun/executor.ts"],"names":[],"mappings":";;AAAA,uCAA0D;AAC1D,qCAAqC;AACrC,2DAA8C;AAC9C,yCAAmD;AACnD,iDAAuD;AACvD,2CAA8C;AAE9C,mCAAsD;AAQtD,SAAwB,kBAAkB,CACxC,0BAAyD,EACzD,OAAwB;IAExB,MAAM,iBAAiB,GAAG,IAAA,0BAAgB,EAAC,OAAO,CAAC,CAAC;IACpD,MAAM,iBAAiB,GAAG,IAAA,mCAA2B,EACnD,0BAA0B,EAC1B,iBAAiB,CAClB,CAAC;IACF,MAAM,EAAE,MAAM,EAAE,OAAO,EAAE,GAAG,0BAA0B,CAAC;IACvD,MAAM,OAAO,GAAG,IAAA,sBAAgB,EAAC,2BAAe,EAAE,iBAAiB,CAAC,CAAC;IACrE,MAAM,cAAc,GAAG,OAAO,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,GAAG,EAAE,OAAO,CAAC,GAAG,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;IAC/D,IAAI,OAAO,EAAE,CAAC;QACZ,eAAM,CAAC,IAAI,CAAC,OAAO,2BAAe,WAAW,CAAC,CAAC;QAC/C,eAAM,CAAC,IAAI,CAAC,YAAY,OAAO,EAAE,CAAC,CAAC;IACrC,CAAC;IACD,IAAI,MAAM,EAAE,CAAC;QACX,eAAM,CAAC,IAAI,CAAC,wBAAwB,OAAO,EAAE,CAAC,CAAC;IACjD,CAAC;SAAM,CAAC;QACN,IAAI,CAAC;YACH,0EAA0E;YAC1E,qCAAqC;YACrC,IAAA,6BAAQ,EAAC,OAAO,EAAE,cAAc,CAAC,CAAC;QACpC,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,eAAM,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;YACpB,OAAO,OAAO,CAAC,OAAO,CAAC;gBACrB,OAAO,EAAE,KAAK;gBACd,OAAO;gBACP,KAAK;aACN,CAAC,CAAC;QACL,CAAC;IACH,CAAC;IAED,OAAO,OAAO,CAAC,OAAO,CAAC;QACrB,OAAO,EAAE,IAAI;QACb,OAAO;KACiB,CAAC,CAAC;AAC9B,CAAC;AArCD,qCAqCC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"schema.js","sourceRoot":"","sources":["../../../../../../packages/nx-plugin/src/executors/autorun/schema.ts"],"names":[],"mappings":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"utils.js","sourceRoot":"","sources":["../../../../../../packages/nx-plugin/src/executors/autorun/utils.ts"],"names":[],"mappings":";;;AAAA,+CAA+E;AAO/E,SAAgB,+BAA+B,CAC7C,OAAmD;IAEnD,MAAM,EAAE,aAAa,EAAE,MAAM,EAAE,WAAW,EAAE,GAAG,OAAO,CAAC;IACvD,OAAO;QACL,GAAG,CAAC,aAAa,IAAI,EAAE,aAAa,EAAE,CAAC;QACvC,GAAG,CAAC,MAAM,IAAI,IAAI,IAAI,EAAE,MAAM,EAAE,CAAC;QACjC,GAAG,CAAC,WAAW,IAAI,EAAE,WAAW,EAAE,CAAC;KACpC,CAAC;AACJ,CAAC;AATD,0EASC;AAED,SAAgB,2BAA2B,CACzC,OAA+C,EAC/C,iBAA4C;IAE5C,MAAM,EAAE,aAAa,EAAE,OAAO,EAAE,MAAM,EAAE,GAAG,OAAO,CAAC;IACnD,OAAO;QACL,GAAG,+BAA+B,CAAC,OAAO,CAAC;QAC3C,GAAG,IAAA,qBAAY,EAAC,OAAO,EAAE,iBAAiB,CAAC;QAC3C,OAAO,EAAE,IAAA,sBAAa,EAAC,EAAE,aAAa,EAAE,GAAG,OAAO,EAAE,EAAE,iBAAiB,CAAC;QACxE,MAAM,EAAE,IAAA,qBAAY,EAAC,EAAE,aAAa,EAAE,GAAG,MAAM,EAAE,EAAE,iBAAiB,CAAC;KACtE,CAAC;AACJ,CAAC;AAXD,kEAWC"}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|