@shell-shock/nx 0.0.78 → 0.0.80

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.
Files changed (69) hide show
  1. package/CHANGELOG.md +20 -0
  2. package/README.md +1 -1
  3. package/dist/base/base-executor.schema.d.ts +16 -4
  4. package/dist/base/base-executor.schema.json +20 -13
  5. package/dist/{base-executor-CXGfAvut.mjs → base-executor-DxPjWb68.mjs} +28 -14
  6. package/dist/base-executor-DxPjWb68.mjs.map +1 -0
  7. package/dist/{base-executor-CjzYhdJI.js → base-executor-X4qL_j3i.js} +27 -13
  8. package/dist/executors/build/executor.d.mts +14 -4
  9. package/dist/executors/build/executor.d.mts.map +1 -1
  10. package/dist/executors/build/executor.d.ts +14 -4
  11. package/dist/executors/build/executor.d.ts.map +1 -1
  12. package/dist/executors/build/executor.js +1 -1
  13. package/dist/executors/build/executor.mjs +1 -1
  14. package/dist/executors/build/executor.mjs.map +1 -1
  15. package/dist/executors/build/schema.d.ts +16 -4
  16. package/dist/executors/build/schema.json +20 -13
  17. package/dist/executors/clean/executor.d.mts +14 -4
  18. package/dist/executors/clean/executor.d.mts.map +1 -1
  19. package/dist/executors/clean/executor.d.ts +14 -4
  20. package/dist/executors/clean/executor.d.ts.map +1 -1
  21. package/dist/executors/clean/executor.js +1 -1
  22. package/dist/executors/clean/executor.mjs +1 -1
  23. package/dist/executors/clean/schema.d.ts +16 -4
  24. package/dist/executors/clean/schema.json +20 -13
  25. package/dist/executors/docs/executor.d.mts +14 -4
  26. package/dist/executors/docs/executor.d.mts.map +1 -1
  27. package/dist/executors/docs/executor.d.ts +14 -4
  28. package/dist/executors/docs/executor.d.ts.map +1 -1
  29. package/dist/executors/docs/executor.js +1 -1
  30. package/dist/executors/docs/executor.mjs +1 -1
  31. package/dist/executors/docs/schema.d.ts +16 -4
  32. package/dist/executors/docs/schema.json +20 -13
  33. package/dist/executors/lint/executor.d.mts +14 -4
  34. package/dist/executors/lint/executor.d.mts.map +1 -1
  35. package/dist/executors/lint/executor.d.ts +14 -4
  36. package/dist/executors/lint/executor.d.ts.map +1 -1
  37. package/dist/executors/lint/executor.js +1 -1
  38. package/dist/executors/lint/executor.mjs +1 -1
  39. package/dist/executors/lint/schema.d.ts +16 -4
  40. package/dist/executors/lint/schema.json +20 -13
  41. package/dist/executors/prepare/executor.d.mts +14 -4
  42. package/dist/executors/prepare/executor.d.mts.map +1 -1
  43. package/dist/executors/prepare/executor.d.ts +14 -4
  44. package/dist/executors/prepare/executor.d.ts.map +1 -1
  45. package/dist/executors/prepare/executor.js +1 -1
  46. package/dist/executors/prepare/executor.mjs +1 -1
  47. package/dist/executors/prepare/schema.d.ts +16 -4
  48. package/dist/executors/prepare/schema.json +20 -13
  49. package/dist/index.d.mts +14 -4
  50. package/dist/index.d.mts.map +1 -1
  51. package/dist/index.d.ts +14 -4
  52. package/dist/index.d.ts.map +1 -1
  53. package/dist/index.js +1 -1
  54. package/dist/index.mjs +1 -1
  55. package/dist/plugin/index.d.mts +1 -1
  56. package/dist/plugin/index.d.mts.map +1 -1
  57. package/dist/plugin/index.d.ts +1 -1
  58. package/dist/plugin/index.d.ts.map +1 -1
  59. package/dist/plugin/index.js +128 -24
  60. package/dist/plugin/index.mjs +128 -24
  61. package/dist/plugin/index.mjs.map +1 -1
  62. package/docs/api/base-executor.schema.md +11 -4
  63. package/docs/api/build/schema.md +11 -4
  64. package/docs/api/clean/schema.md +11 -4
  65. package/docs/api/docs/schema.md +11 -4
  66. package/docs/api/lint/schema.md +11 -4
  67. package/docs/api/prepare/schema.md +11 -4
  68. package/package.json +16 -16
  69. package/dist/base-executor-CXGfAvut.mjs.map +0 -1
@@ -6,7 +6,6 @@
6
6
 
7
7
  ## `config`
8
8
  - **Type**: `string`
9
- - **Default**: `"{projectRoot}/powerlines.config.ts"`
10
9
 
11
10
  > Powerlines Configuration File
12
11
 
@@ -16,7 +15,6 @@ The path to the Powerlines configuration file. Alias for `configFile`.
16
15
 
17
16
  ## `configFile`
18
17
  - **Type**: `string`
19
- - **Default**: `"{projectRoot}/powerlines.config.ts"`
20
18
 
21
19
  > Powerlines Configuration File
22
20
 
@@ -35,7 +33,6 @@ The entry file(s) that serve as the input for the project
35
33
 
36
34
  ## `tsconfig`
37
35
  - **Type**: `string`
38
- - **Default**: `"{projectRoot}/tsconfig.json"`
39
36
 
40
37
  > TSConfig Path
41
38
 
@@ -71,6 +68,15 @@ A directory path to copy the build artifacts into
71
68
  Generate a sourcemap
72
69
 
73
70
 
71
+ ## `minify`
72
+ - **Type**: `boolean`
73
+
74
+ > Minify
75
+
76
+
77
+ Minify the output
78
+
79
+
74
80
  ## `format`
75
81
  - **Type**: `array`
76
82
  - **Default**: `["cjs","esm"]`
@@ -83,7 +89,6 @@ The format to build
83
89
 
84
90
  ## `platform`
85
91
  - **Type**: `string`
86
- - **Default**: `"neutral"`
87
92
 
88
93
  > Platform
89
94
 
@@ -150,6 +155,8 @@ The log level to use for the build process
150
155
  The `assets` values
151
156
 
152
157
 
158
+ ## `additionalArgs`
159
+
153
160
  ## `autoInstall`
154
161
  - **Type**: `boolean`
155
162
 
@@ -6,7 +6,6 @@
6
6
 
7
7
  ## `config`
8
8
  - **Type**: `string`
9
- - **Default**: `"{projectRoot}/powerlines.config.ts"`
10
9
 
11
10
  > Powerlines Configuration File
12
11
 
@@ -16,7 +15,6 @@ The path to the Powerlines configuration file. Alias for `configFile`.
16
15
 
17
16
  ## `configFile`
18
17
  - **Type**: `string`
19
- - **Default**: `"{projectRoot}/powerlines.config.ts"`
20
18
 
21
19
  > Powerlines Configuration File
22
20
 
@@ -35,7 +33,6 @@ The entry file(s) that serve as the input for the project
35
33
 
36
34
  ## `tsconfig`
37
35
  - **Type**: `string`
38
- - **Default**: `"{projectRoot}/tsconfig.json"`
39
36
 
40
37
  > TSConfig Path
41
38
 
@@ -71,6 +68,15 @@ A directory path to copy the build artifacts into
71
68
  Generate a sourcemap
72
69
 
73
70
 
71
+ ## `minify`
72
+ - **Type**: `boolean`
73
+
74
+ > Minify
75
+
76
+
77
+ Minify the output
78
+
79
+
74
80
  ## `format`
75
81
  - **Type**: `array`
76
82
  - **Default**: `["cjs","esm"]`
@@ -83,7 +89,6 @@ The format to build
83
89
 
84
90
  ## `platform`
85
91
  - **Type**: `string`
86
- - **Default**: `"neutral"`
87
92
 
88
93
  > Platform
89
94
 
@@ -150,6 +155,8 @@ The log level to use for the build process
150
155
  The `assets` values
151
156
 
152
157
 
158
+ ## `additionalArgs`
159
+
153
160
  ## `autoInstall`
154
161
  - **Type**: `boolean`
155
162
 
@@ -6,7 +6,6 @@
6
6
 
7
7
  ## `config`
8
8
  - **Type**: `string`
9
- - **Default**: `"{projectRoot}/powerlines.config.ts"`
10
9
 
11
10
  > Powerlines Configuration File
12
11
 
@@ -16,7 +15,6 @@ The path to the Powerlines configuration file. Alias for `configFile`.
16
15
 
17
16
  ## `configFile`
18
17
  - **Type**: `string`
19
- - **Default**: `"{projectRoot}/powerlines.config.ts"`
20
18
 
21
19
  > Powerlines Configuration File
22
20
 
@@ -35,7 +33,6 @@ The entry file(s) that serve as the input for the project
35
33
 
36
34
  ## `tsconfig`
37
35
  - **Type**: `string`
38
- - **Default**: `"{projectRoot}/tsconfig.json"`
39
36
 
40
37
  > TSConfig Path
41
38
 
@@ -71,6 +68,15 @@ A directory path to copy the build artifacts into
71
68
  Generate a sourcemap
72
69
 
73
70
 
71
+ ## `minify`
72
+ - **Type**: `boolean`
73
+
74
+ > Minify
75
+
76
+
77
+ Minify the output
78
+
79
+
74
80
  ## `format`
75
81
  - **Type**: `array`
76
82
  - **Default**: `["cjs","esm"]`
@@ -83,7 +89,6 @@ The format to build
83
89
 
84
90
  ## `platform`
85
91
  - **Type**: `string`
86
- - **Default**: `"neutral"`
87
92
 
88
93
  > Platform
89
94
 
@@ -150,6 +155,8 @@ The log level to use for the build process
150
155
  The `assets` values
151
156
 
152
157
 
158
+ ## `additionalArgs`
159
+
153
160
  ## `autoInstall`
154
161
  - **Type**: `boolean`
155
162
 
@@ -6,7 +6,6 @@
6
6
 
7
7
  ## `config`
8
8
  - **Type**: `string`
9
- - **Default**: `"{projectRoot}/powerlines.config.ts"`
10
9
 
11
10
  > Powerlines Configuration File
12
11
 
@@ -16,7 +15,6 @@ The path to the Powerlines configuration file. Alias for `configFile`.
16
15
 
17
16
  ## `configFile`
18
17
  - **Type**: `string`
19
- - **Default**: `"{projectRoot}/powerlines.config.ts"`
20
18
 
21
19
  > Powerlines Configuration File
22
20
 
@@ -35,7 +33,6 @@ The entry file(s) that serve as the input for the project
35
33
 
36
34
  ## `tsconfig`
37
35
  - **Type**: `string`
38
- - **Default**: `"{projectRoot}/tsconfig.json"`
39
36
 
40
37
  > TSConfig Path
41
38
 
@@ -71,6 +68,15 @@ A directory path to copy the build artifacts into
71
68
  Generate a sourcemap
72
69
 
73
70
 
71
+ ## `minify`
72
+ - **Type**: `boolean`
73
+
74
+ > Minify
75
+
76
+
77
+ Minify the output
78
+
79
+
74
80
  ## `format`
75
81
  - **Type**: `array`
76
82
  - **Default**: `["cjs","esm"]`
@@ -83,7 +89,6 @@ The format to build
83
89
 
84
90
  ## `platform`
85
91
  - **Type**: `string`
86
- - **Default**: `"neutral"`
87
92
 
88
93
  > Platform
89
94
 
@@ -150,6 +155,8 @@ The log level to use for the build process
150
155
  The `assets` values
151
156
 
152
157
 
158
+ ## `additionalArgs`
159
+
153
160
  ## `autoInstall`
154
161
  - **Type**: `boolean`
155
162
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@shell-shock/nx",
3
- "version": "0.0.78",
3
+ "version": "0.0.80",
4
4
  "description": "A Nx plugin to support Shell Shock development in Nx monorepos.",
5
5
  "repository": {
6
6
  "type": "github",
@@ -80,30 +80,30 @@
80
80
  "typings": "dist/index.d.ts",
81
81
  "peerDependencies": { "nx": ">=22.5.0", "powerlines": ">=0.42.32" },
82
82
  "dependencies": {
83
- "@nx/devkit": "22.6.5",
84
- "@shell-shock/core": "^0.17.6",
85
- "@storm-software/config": "^1.137.31",
86
- "@storm-software/config-tools": "^1.189.77",
87
- "@storm-software/workspace-tools": "^1.295.55",
88
- "@stryke/type-checks": "^0.6.1",
89
- "@stryke/string-format": "^0.17.9",
90
- "@stryke/hash": "^0.13.19",
91
- "@stryke/path": "^0.27.4",
83
+ "@nx/devkit": "22.7.0",
84
+ "@shell-shock/core": "^0.17.8",
85
+ "@storm-software/config": "^1.137.34",
86
+ "@storm-software/config-tools": "^1.190.1",
87
+ "@storm-software/workspace-tools": "^1.295.60",
88
+ "@stryke/type-checks": "^0.6.4",
89
+ "@stryke/string-format": "^0.17.12",
90
+ "@stryke/hash": "^0.13.22",
91
+ "@stryke/path": "^0.28.1",
92
92
  "defu": "^6.1.7",
93
93
  "jiti": "^2.6.1",
94
94
  "untyped": "^1.5.2"
95
95
  },
96
96
  "devDependencies": {
97
- "@powerlines/nx": "^0.12.13",
98
- "@powerlines/plugin-tsdown": "^0.1.340",
99
- "@powerlines/plugin-untyped": "^0.2.352",
100
- "@storm-software/testing-tools": "^1.119.152",
97
+ "@powerlines/nx": "^0.13.22",
98
+ "@powerlines/plugin-tsdown": "^0.1.389",
99
+ "@powerlines/plugin-untyped": "^0.2.402",
100
+ "@storm-software/testing-tools": "^1.119.155",
101
101
  "@types/node": "^25.6.0",
102
102
  "eslint-flat-config-utils": "^2.1.4",
103
103
  "jsonc-eslint-parser": "^2.4.2",
104
- "powerlines": "^0.42.40"
104
+ "powerlines": "^0.44.12"
105
105
  },
106
106
  "publishConfig": { "access": "public" },
107
107
  "executors": "./executors.json",
108
- "gitHead": "592aee8162fccb2d8547f6cf31b820aca3ae13ec"
108
+ "gitHead": "832c19e668deb4d29b5e0219a7708d111790f607"
109
109
  }
@@ -1 +0,0 @@
1
- {"version":3,"file":"base-executor-CXGfAvut.mjs","names":[],"sources":["../src/base/base-executor.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Shell Shock\n\n This code was released as part of the Shell Shock project. Shell Shock\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/shell-shock.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/shell-shock\n Documentation: https://docs.stormsoftware.com/projects/shell-shock\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport type { ExecutorContext, PromiseExecutor } from \"@nx/devkit\";\nimport type { ShellShockAPI, UserConfig } from \"@shell-shock/core\";\nimport { writeError } from \"@storm-software/config-tools/logger\";\nimport type { StormWorkspaceConfig } from \"@storm-software/config/types\";\nimport { withRunExecutor } from \"@storm-software/workspace-tools/base/base-executor\";\nimport type { BaseExecutorResult } from \"@storm-software/workspace-tools/types\";\nimport { isError } from \"@stryke/type-checks/is-error\";\nimport defu from \"defu\";\nimport { createJiti } from \"jiti\";\nimport type { InlineConfig, PowerlinesCommand } from \"powerlines\";\nimport type { BaseExecutorSchema } from \"./base-executor.schema\";\n\nexport type ShellShockExecutorContext<\n TCommand extends PowerlinesCommand = PowerlinesCommand,\n TExecutorSchema extends BaseExecutorSchema = BaseExecutorSchema\n> = ExecutorContext & {\n projectName: string;\n command: TCommand;\n options: TExecutorSchema;\n inlineConfig: InlineConfig;\n workspaceConfig: StormWorkspaceConfig;\n};\n\n/**\n * A utility function to create a Shell Shock executor that can be used with the `withRunExecutor` function.\n *\n * @remarks\n * This function is designed to simplify the creation of Shell Shock executors by providing a consistent interface and error handling.\n *\n * @param command - The command that the executor will handle (e.g., \"new\", \"prepare\", \"build\", etc.).\n * @param executorFn - The function that will be executed when the command is run.\n * @returns A Promise that resolves to the result of the executor function.\n */\nexport function withExecutor<\n TCommand extends PowerlinesCommand = PowerlinesCommand,\n TExecutorSchema extends BaseExecutorSchema = BaseExecutorSchema\n>(\n command: TCommand,\n executorFn: (\n context: ShellShockExecutorContext<TCommand, TExecutorSchema>,\n api: ShellShockAPI\n ) =>\n | Promise<BaseExecutorResult | null | undefined>\n | BaseExecutorResult\n | null\n | undefined\n): PromiseExecutor<TExecutorSchema> {\n return withRunExecutor(\n `Shell Shock ${command} command executor`,\n async (\n options: TExecutorSchema,\n context: ExecutorContext,\n workspaceConfig: StormWorkspaceConfig\n ): Promise<BaseExecutorResult | null | undefined> => {\n if (!context.projectName) {\n throw new Error(\n \"The executor requires `projectName` on the context object.\"\n );\n }\n\n if (\n !context.projectName ||\n !context.projectsConfigurations?.projects ||\n !context.projectsConfigurations.projects[context.projectName] ||\n !context.projectsConfigurations.projects[context.projectName]?.root\n ) {\n throw new Error(\n \"The executor requires `projectsConfigurations` on the context object.\"\n );\n }\n\n const projectConfig =\n context.projectsConfigurations.projects[context.projectName]!;\n\n const jiti = createJiti(context.root, { cache: false });\n const { ShellShockAPI } = await jiti.import<{\n ShellShockAPI: typeof import(\"@shell-shock/core\").ShellShockAPI;\n }>(jiti.esmResolve(\"@shell-shock/core\"));\n\n const api = await ShellShockAPI.from(\n defu(\n {\n name: projectConfig.name,\n root: projectConfig.root,\n sourceRoot: projectConfig.sourceRoot,\n description: projectConfig.metadata?.description,\n projectType: projectConfig.projectType,\n output: {\n path: options.outputPath\n }\n },\n options,\n workspaceConfig.workspaceRoot\n ) as UserConfig\n );\n\n try {\n return await Promise.resolve(\n executorFn(\n defu(\n {\n projectName: context.projectName,\n options,\n workspaceConfig,\n inlineConfig: {\n command,\n configFile: options.configFile\n },\n command\n },\n context\n ),\n api\n )\n );\n } catch (error) {\n writeError(\n `An error occurred while executing the Shell Shock ${\n command\n } command executor: ${\n isError(error)\n ? `${error.message}\n\n${error.stack}`\n : \"Unknown error\"\n }`\n );\n\n return { success: false };\n } finally {\n await api.finalize();\n }\n },\n {\n skipReadingConfig: false,\n hooks: {\n applyDefaultOptions: (options: Partial<TExecutorSchema>) => {\n options.outputPath ??= \"dist/{projectRoot}\";\n options.configFile ??= \"{projectRoot}/shell-shock.config.ts\";\n\n return options as TExecutorSchema;\n }\n }\n }\n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