@powerlines/engine 0.47.4 → 0.49.1
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/dist/api/build.cjs +66 -0
- package/dist/api/build.d.cts +14 -0
- package/dist/api/build.d.cts.map +1 -0
- package/dist/api/build.d.mts +14 -0
- package/dist/api/build.d.mts.map +1 -0
- package/dist/api/build.mjs +64 -0
- package/dist/api/build.mjs.map +1 -0
- package/dist/api/clean.cjs +28 -0
- package/dist/api/clean.d.cts +14 -0
- package/dist/api/clean.d.cts.map +1 -0
- package/dist/api/clean.d.mts +14 -0
- package/dist/api/clean.d.mts.map +1 -0
- package/dist/api/clean.mjs +28 -0
- package/dist/api/clean.mjs.map +1 -0
- package/dist/api/create.cjs +59 -0
- package/dist/api/create.d.cts +14 -0
- package/dist/api/create.d.cts.map +1 -0
- package/dist/api/create.d.mts +14 -0
- package/dist/api/create.d.mts.map +1 -0
- package/dist/api/create.mjs +57 -0
- package/dist/api/create.mjs.map +1 -0
- package/dist/api/deploy.cjs +24 -0
- package/dist/api/deploy.d.cts +17 -0
- package/dist/api/deploy.d.cts.map +1 -0
- package/dist/api/deploy.d.mts +17 -0
- package/dist/api/deploy.d.mts.map +1 -0
- package/dist/api/deploy.mjs +24 -0
- package/dist/api/deploy.mjs.map +1 -0
- package/dist/api/docs.cjs +24 -0
- package/dist/api/docs.d.cts +17 -0
- package/dist/api/docs.d.cts.map +1 -0
- package/dist/api/docs.d.mts +17 -0
- package/dist/api/docs.d.mts.map +1 -0
- package/dist/api/docs.mjs +24 -0
- package/dist/api/docs.mjs.map +1 -0
- package/dist/api/lint.cjs +27 -0
- package/dist/api/lint.d.cts +17 -0
- package/dist/api/lint.d.cts.map +1 -0
- package/dist/api/lint.d.mts +17 -0
- package/dist/api/lint.d.mts.map +1 -0
- package/dist/api/lint.mjs +27 -0
- package/dist/api/lint.mjs.map +1 -0
- package/dist/api/prepare.cjs +68 -0
- package/dist/api/prepare.d.cts +14 -0
- package/dist/api/prepare.d.cts.map +1 -0
- package/dist/api/prepare.d.mts +14 -0
- package/dist/api/prepare.d.mts.map +1 -0
- package/dist/api/prepare.mjs +68 -0
- package/dist/api/prepare.mjs.map +1 -0
- package/dist/api/test.cjs +27 -0
- package/dist/api/test.d.cts +17 -0
- package/dist/api/test.d.cts.map +1 -0
- package/dist/api/test.d.mts +17 -0
- package/dist/api/test.d.mts.map +1 -0
- package/dist/api/test.mjs +27 -0
- package/dist/api/test.mjs.map +1 -0
- package/dist/api/types.cjs +70 -0
- package/dist/api/types.d.cts +17 -0
- package/dist/api/types.d.cts.map +1 -0
- package/dist/api/types.d.mts +17 -0
- package/dist/api/types.d.mts.map +1 -0
- package/dist/api/types.mjs +70 -0
- package/dist/api/types.mjs.map +1 -0
- package/dist/api-BgyEi2hF.d.mts +138 -0
- package/dist/api-BgyEi2hF.d.mts.map +1 -0
- package/dist/api-DcHfCjQK.d.cts +138 -0
- package/dist/api-DcHfCjQK.d.cts.map +1 -0
- package/dist/api.cjs +39 -1268
- package/dist/api.d.cts +11 -300
- package/dist/api.d.cts.map +1 -1
- package/dist/api.d.mts +11 -300
- package/dist/api.d.mts.map +1 -1
- package/dist/api.mjs +31 -1264
- package/dist/api.mjs.map +1 -1
- package/dist/config-ByLyzMI0.d.mts +204 -0
- package/dist/config-ByLyzMI0.d.mts.map +1 -0
- package/dist/config-DKEmqMrh.d.cts +204 -0
- package/dist/config-DKEmqMrh.d.cts.map +1 -0
- package/dist/context/engine-context.cjs +177 -0
- package/dist/context/engine-context.d.cts +2 -0
- package/dist/context/engine-context.d.mts +2 -0
- package/dist/context/engine-context.mjs +175 -0
- package/dist/context/engine-context.mjs.map +1 -0
- package/dist/context/index.cjs +2 -9
- package/dist/context/index.d.cts +2 -150
- package/dist/context/index.d.mts +2 -150
- package/dist/context/index.mjs +2 -4
- package/dist/context-D0_a0kRO.d.cts +149 -0
- package/dist/context-D0_a0kRO.d.cts.map +1 -0
- package/dist/context-DcXV6_GL.d.mts +149 -0
- package/dist/context-DcXV6_GL.d.mts.map +1 -0
- package/dist/engine-Dz6BvkFY.cjs +590 -0
- package/dist/engine-context-B8K6Jtkk.d.cts +53 -0
- package/dist/engine-context-B8K6Jtkk.d.cts.map +1 -0
- package/dist/engine-context-DKlA5Pgu.d.mts +53 -0
- package/dist/engine-context-DKlA5Pgu.d.mts.map +1 -0
- package/dist/engine-q6YKXXcB.mjs +571 -0
- package/dist/engine-q6YKXXcB.mjs.map +1 -0
- package/dist/engine.cjs +6 -0
- package/dist/engine.d.cts +143 -0
- package/dist/engine.d.cts.map +1 -0
- package/dist/engine.d.mts +143 -0
- package/dist/engine.d.mts.map +1 -0
- package/dist/engine.mjs +3 -0
- package/dist/helpers/create-execution-host.cjs +57 -0
- package/dist/helpers/create-execution-host.d.cts +20 -0
- package/dist/helpers/create-execution-host.d.cts.map +1 -0
- package/dist/helpers/create-execution-host.d.mts +20 -0
- package/dist/helpers/create-execution-host.d.mts.map +1 -0
- package/dist/helpers/create-execution-host.mjs +57 -0
- package/dist/helpers/create-execution-host.mjs.map +1 -0
- package/dist/helpers/finalize.cjs +26 -0
- package/dist/helpers/finalize.d.cts +12 -0
- package/dist/helpers/finalize.d.cts.map +1 -0
- package/dist/helpers/finalize.d.mts +12 -0
- package/dist/helpers/finalize.d.mts.map +1 -0
- package/dist/helpers/finalize.mjs +26 -0
- package/dist/helpers/finalize.mjs.map +1 -0
- package/dist/helpers/index.cjs +12 -0
- package/dist/helpers/index.d.cts +5 -0
- package/dist/helpers/index.d.mts +5 -0
- package/dist/helpers/index.mjs +6 -0
- package/dist/helpers/rpc.cjs +139 -0
- package/dist/helpers/rpc.d.cts +7 -0
- package/dist/helpers/rpc.d.cts.map +1 -0
- package/dist/helpers/rpc.d.mts +7 -0
- package/dist/helpers/rpc.d.mts.map +1 -0
- package/dist/helpers/rpc.mjs +139 -0
- package/dist/helpers/rpc.mjs.map +1 -0
- package/dist/helpers/stream.cjs +119 -0
- package/dist/helpers/stream.d.cts +45 -0
- package/dist/helpers/stream.d.cts.map +1 -0
- package/dist/helpers/stream.d.mts +45 -0
- package/dist/helpers/stream.d.mts.map +1 -0
- package/dist/helpers/stream.mjs +117 -0
- package/dist/helpers/stream.mjs.map +1 -0
- package/dist/index-BVVgDSdq.d.cts +1 -0
- package/dist/index-BVVgDSdq.d.mts +1 -0
- package/dist/index.cjs +8 -748
- package/dist/index.d.cts +6 -140
- package/dist/index.d.mts +6 -140
- package/dist/index.mjs +4 -747
- package/package.json +102 -132
- package/dist/_internal/worker.cjs +0 -5192
- package/dist/_internal/worker.d.cts +0 -46
- package/dist/_internal/worker.d.cts.map +0 -1
- package/dist/_internal/worker.d.mts +0 -46
- package/dist/_internal/worker.d.mts.map +0 -1
- package/dist/_internal/worker.mjs +0 -5153
- package/dist/_internal/worker.mjs.map +0 -1
- package/dist/base-context-DLemGRbd.cjs +0 -322
- package/dist/base-context-DUha4Lz-.mjs +0 -315
- package/dist/base-context-DUha4Lz-.mjs.map +0 -1
- package/dist/context/index.d.cts.map +0 -1
- package/dist/context/index.d.mts.map +0 -1
- package/dist/engine-context-BfFiKN53.mjs +0 -86
- package/dist/engine-context-BfFiKN53.mjs.map +0 -1
- package/dist/engine-context-D0y88i_J.cjs +0 -91
- package/dist/execution-context-CE5H90Um.mjs +0 -2845
- package/dist/execution-context-CE5H90Um.mjs.map +0 -1
- package/dist/execution-context-CnyaM3Ul.cjs +0 -2889
- package/dist/execution-context-NyDjVZ6T.d.cts +0 -647
- package/dist/execution-context-NyDjVZ6T.d.cts.map +0 -1
- package/dist/execution-context-YrjFeD9k.d.mts +0 -647
- package/dist/execution-context-YrjFeD9k.d.mts.map +0 -1
- package/dist/fs-CeEdzPKE.cjs +0 -262
- package/dist/fs-Dcle8lUp.mjs +0 -226
- package/dist/fs-Dcle8lUp.mjs.map +0 -1
- package/dist/index.d.cts.map +0 -1
- package/dist/index.d.mts.map +0 -1
- package/dist/index.mjs.map +0 -1
- package/dist/rpc/client.cjs +0 -74
- package/dist/rpc/client.d.cts +0 -31
- package/dist/rpc/client.d.cts.map +0 -1
- package/dist/rpc/client.d.mts +0 -31
- package/dist/rpc/client.d.mts.map +0 -1
- package/dist/rpc/client.mjs +0 -71
- package/dist/rpc/client.mjs.map +0 -1
- package/dist/rpc/serialization.cjs +0 -82
- package/dist/rpc/serialization.d.cts +0 -46
- package/dist/rpc/serialization.d.cts.map +0 -1
- package/dist/rpc/serialization.d.mts +0 -46
- package/dist/rpc/serialization.d.mts.map +0 -1
- package/dist/rpc/serialization.mjs +0 -76
- package/dist/rpc/serialization.mjs.map +0 -1
- package/dist/rpc/server.cjs +0 -69
- package/dist/rpc/server.d.cts +0 -29
- package/dist/rpc/server.d.cts.map +0 -1
- package/dist/rpc/server.d.mts +0 -29
- package/dist/rpc/server.d.mts.map +0 -1
- package/dist/rpc/server.mjs +0 -66
- package/dist/rpc/server.mjs.map +0 -1
- package/dist/rpc/types.cjs +0 -0
- package/dist/rpc/types.d.cts +0 -70
- package/dist/rpc/types.d.cts.map +0 -1
- package/dist/rpc/types.d.mts +0 -70
- package/dist/rpc/types.d.mts.map +0 -1
- package/dist/rpc/types.mjs +0 -1
- package/dist/schemas.cjs +0 -9
- package/dist/schemas.d.cts +0 -127
- package/dist/schemas.d.cts.map +0 -1
- package/dist/schemas.d.mts +0 -127
- package/dist/schemas.d.mts.map +0 -1
- package/dist/schemas.mjs +0 -3
- package/dist/storage/base.cjs +0 -216
- package/dist/storage/base.d.cts +0 -199
- package/dist/storage/base.d.cts.map +0 -1
- package/dist/storage/base.d.mts +0 -199
- package/dist/storage/base.d.mts.map +0 -1
- package/dist/storage/base.mjs +0 -215
- package/dist/storage/base.mjs.map +0 -1
- package/dist/storage/file-system.cjs +0 -180
- package/dist/storage/file-system.d.cts +0 -127
- package/dist/storage/file-system.d.cts.map +0 -1
- package/dist/storage/file-system.d.mts +0 -127
- package/dist/storage/file-system.d.mts.map +0 -1
- package/dist/storage/file-system.mjs +0 -179
- package/dist/storage/file-system.mjs.map +0 -1
- package/dist/storage/helpers.cjs +0 -37
- package/dist/storage/helpers.d.cts +0 -25
- package/dist/storage/helpers.d.cts.map +0 -1
- package/dist/storage/helpers.d.mts +0 -25
- package/dist/storage/helpers.d.mts.map +0 -1
- package/dist/storage/helpers.mjs +0 -34
- package/dist/storage/helpers.mjs.map +0 -1
- package/dist/storage/index.cjs +0 -12
- package/dist/storage/index.d.cts +0 -5
- package/dist/storage/index.d.mts +0 -5
- package/dist/storage/index.mjs +0 -6
- package/dist/storage/virtual.cjs +0 -98
- package/dist/storage/virtual.d.cts +0 -80
- package/dist/storage/virtual.d.cts.map +0 -1
- package/dist/storage/virtual.d.mts +0 -80
- package/dist/storage/virtual.d.mts.map +0 -1
- package/dist/storage/virtual.mjs +0 -97
- package/dist/storage/virtual.mjs.map +0 -1
- package/dist/ts-morph-BbM83PT9.cjs +0 -114
- package/dist/ts-morph-C6YBNc46.mjs +0 -102
- package/dist/ts-morph-C6YBNc46.mjs.map +0 -1
- package/dist/tsconfig-DeKMGasE.cjs +0 -198
- package/dist/tsconfig-HzJsMUrr.mjs +0 -155
- package/dist/tsconfig-HzJsMUrr.mjs.map +0 -1
- package/dist/typescript/index.cjs +0 -13
- package/dist/typescript/index.d.cts +0 -106
- package/dist/typescript/index.d.cts.map +0 -1
- package/dist/typescript/index.d.mts +0 -106
- package/dist/typescript/index.d.mts.map +0 -1
- package/dist/typescript/index.mjs +0 -4
- /package/dist/{chunk-C0xms8kb.cjs → chunk-C_NdSu1c.cjs} +0 -0
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { r as EngineResolvedConfig } from "../config-DKEmqMrh.cjs";
|
|
2
|
+
import { r as EngineSystemContext } from "../context-D0_a0kRO.cjs";
|
|
3
|
+
import { ExecutionContext } from "@powerlines/core";
|
|
4
|
+
|
|
5
|
+
//#region src/api/docs.d.ts
|
|
6
|
+
/**
|
|
7
|
+
* Generate the project's documentation.
|
|
8
|
+
*
|
|
9
|
+
* @remarks
|
|
10
|
+
* This function serves as the main entry point for the documentation generation process, orchestrating the execution of documentation hooks across different environments defined in the project configuration. It ensures that all relevant documentation operations are performed in a structured manner, allowing for pre-documentation, main documentation, and post-documentation hooks to be executed at the appropriate stages of the process. The function also utilizes a timer to measure the duration of the documentation operation, providing insights into the performance of the documentation process.
|
|
11
|
+
*
|
|
12
|
+
* @param context - The execution context for the documentation process, which provides access to the project configuration, environment, and utility functions for performing the documentation operation. The context is used to manage the state and behavior of the documentation process, allowing for hooks to be called at different stages of the documentation and for environment-specific configurations to be applied.
|
|
13
|
+
*/
|
|
14
|
+
declare function docs<TResolvedConfig extends EngineResolvedConfig, TSystemContext extends EngineSystemContext>(context: ExecutionContext<TResolvedConfig, TSystemContext>): Promise<void>;
|
|
15
|
+
//#endregion
|
|
16
|
+
export { docs };
|
|
17
|
+
//# sourceMappingURL=docs.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"docs.d.cts","names":[],"sources":["../../src/api/docs.ts"],"mappings":";;;;;;;AAgCA;;;;;;iBAAsB,IAAA,yBACI,oBAAA,yBACD,mBAAA,CAAA,CACvB,OAAA,EAAS,gBAAA,CAAiB,eAAA,EAAiB,cAAA,IAAe,OAAA"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { r as EngineResolvedConfig } from "../config-ByLyzMI0.mjs";
|
|
2
|
+
import { r as EngineSystemContext } from "../context-DcXV6_GL.mjs";
|
|
3
|
+
import { ExecutionContext } from "@powerlines/core";
|
|
4
|
+
|
|
5
|
+
//#region src/api/docs.d.ts
|
|
6
|
+
/**
|
|
7
|
+
* Generate the project's documentation.
|
|
8
|
+
*
|
|
9
|
+
* @remarks
|
|
10
|
+
* This function serves as the main entry point for the documentation generation process, orchestrating the execution of documentation hooks across different environments defined in the project configuration. It ensures that all relevant documentation operations are performed in a structured manner, allowing for pre-documentation, main documentation, and post-documentation hooks to be executed at the appropriate stages of the process. The function also utilizes a timer to measure the duration of the documentation operation, providing insights into the performance of the documentation process.
|
|
11
|
+
*
|
|
12
|
+
* @param context - The execution context for the documentation process, which provides access to the project configuration, environment, and utility functions for performing the documentation operation. The context is used to manage the state and behavior of the documentation process, allowing for hooks to be called at different stages of the documentation and for environment-specific configurations to be applied.
|
|
13
|
+
*/
|
|
14
|
+
declare function docs<TResolvedConfig extends EngineResolvedConfig, TSystemContext extends EngineSystemContext>(context: ExecutionContext<TResolvedConfig, TSystemContext>): Promise<void>;
|
|
15
|
+
//#endregion
|
|
16
|
+
export { docs };
|
|
17
|
+
//# sourceMappingURL=docs.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"docs.d.mts","names":[],"sources":["../../src/api/docs.ts"],"mappings":";;;;;;;AAgCA;;;;;;iBAAsB,IAAA,yBACI,oBAAA,yBACD,mBAAA,CAAA,CACvB,OAAA,EAAS,gBAAA,CAAiB,eAAA,EAAiB,cAAA,IAAe,OAAA"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { prepare } from "./prepare.mjs";
|
|
2
|
+
import { executeEnvironments } from "@powerlines/core/lib/environment";
|
|
3
|
+
|
|
4
|
+
//#region src/api/docs.ts
|
|
5
|
+
/**
|
|
6
|
+
* Generate the project's documentation.
|
|
7
|
+
*
|
|
8
|
+
* @remarks
|
|
9
|
+
* This function serves as the main entry point for the documentation generation process, orchestrating the execution of documentation hooks across different environments defined in the project configuration. It ensures that all relevant documentation operations are performed in a structured manner, allowing for pre-documentation, main documentation, and post-documentation hooks to be executed at the appropriate stages of the process. The function also utilizes a timer to measure the duration of the documentation operation, providing insights into the performance of the documentation process.
|
|
10
|
+
*
|
|
11
|
+
* @param context - The execution context for the documentation process, which provides access to the project configuration, environment, and utility functions for performing the documentation operation. The context is used to manage the state and behavior of the documentation process, allowing for hooks to be called at different stages of the documentation and for environment-specific configurations to be applied.
|
|
12
|
+
*/
|
|
13
|
+
async function docs(context) {
|
|
14
|
+
const timer = context.timer("Documentation");
|
|
15
|
+
await prepare(context);
|
|
16
|
+
await executeEnvironments(context, async (env) => {
|
|
17
|
+
await context.callHook("docs", { environment: env });
|
|
18
|
+
});
|
|
19
|
+
timer();
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
//#endregion
|
|
23
|
+
export { docs };
|
|
24
|
+
//# sourceMappingURL=docs.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"docs.mjs","names":[],"sources":["../../src/api/docs.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Powerlines\n\n This code was released as part of the Powerlines project. Powerlines\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/powerlines.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/powerlines\n Documentation: https://docs.stormsoftware.com/projects/powerlines\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport { ExecutionContext } from \"@powerlines/core\";\nimport { executeEnvironments } from \"@powerlines/core/lib/environment\";\nimport { EngineResolvedConfig } from \"../types/config\";\nimport { EngineSystemContext } from \"../types/context\";\nimport { prepare } from \"./prepare\";\n\n/**\n * Generate the project's documentation.\n *\n * @remarks\n * This function serves as the main entry point for the documentation generation process, orchestrating the execution of documentation hooks across different environments defined in the project configuration. It ensures that all relevant documentation operations are performed in a structured manner, allowing for pre-documentation, main documentation, and post-documentation hooks to be executed at the appropriate stages of the process. The function also utilizes a timer to measure the duration of the documentation operation, providing insights into the performance of the documentation process.\n *\n * @param context - The execution context for the documentation process, which provides access to the project configuration, environment, and utility functions for performing the documentation operation. The context is used to manage the state and behavior of the documentation process, allowing for hooks to be called at different stages of the documentation and for environment-specific configurations to be applied.\n */\nexport async function docs<\n TResolvedConfig extends EngineResolvedConfig,\n TSystemContext extends EngineSystemContext\n>(context: ExecutionContext<TResolvedConfig, TSystemContext>) {\n const timer = context.timer(\"Documentation\");\n\n await prepare<TResolvedConfig, TSystemContext>(context);\n await executeEnvironments(context, async env => {\n await context.callHook(\"docs\", {\n environment: env\n });\n });\n\n timer();\n}\n"],"mappings":";;;;;;;;;;;;AAgCA,eAAsB,KAGpB,SAA4D;CAC5D,MAAM,QAAQ,QAAQ,MAAM,eAAe;CAE3C,MAAM,QAAyC,OAAO;CACtD,MAAM,oBAAoB,SAAS,OAAM,QAAO;EAC9C,MAAM,QAAQ,SAAS,QAAQ,EAC7B,aAAa,IACf,CAAC;CACH,CAAC;CAED,MAAM;AACR"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
2
|
+
const require_api_prepare = require('./prepare.cjs');
|
|
3
|
+
let _powerlines_core_lib_environment = require("@powerlines/core/lib/environment");
|
|
4
|
+
|
|
5
|
+
//#region src/api/lint.ts
|
|
6
|
+
/**
|
|
7
|
+
* Lint the project's source files and report any issues found.
|
|
8
|
+
*
|
|
9
|
+
* @remarks
|
|
10
|
+
* This function serves as the main entry point for the linting process, orchestrating the execution of linting hooks across different environments defined in the project configuration. It ensures that all relevant linting operations are performed in a structured manner, allowing for pre-linting, main linting, and post-linting hooks to be executed at the appropriate stages of the process. The function also utilizes a timer to measure the duration of the linting operation, providing insights into the performance of the linting process.
|
|
11
|
+
*
|
|
12
|
+
* @param context - The execution context for the lint process, which provides access to the project configuration, environment, and utility functions for performing the lint operation. The context is used to manage the state and behavior of the lint process, allowing for hooks to be called at different stages of the lint and for environment-specific configurations to be applied.
|
|
13
|
+
*/
|
|
14
|
+
async function lint(context) {
|
|
15
|
+
const timer = context.timer("Linting");
|
|
16
|
+
await require_api_prepare.prepare(context);
|
|
17
|
+
await (0, _powerlines_core_lib_environment.executeEnvironments)(context, async (env) => {
|
|
18
|
+
await context.callHook("lint", {
|
|
19
|
+
environment: env,
|
|
20
|
+
sequential: false
|
|
21
|
+
});
|
|
22
|
+
});
|
|
23
|
+
timer();
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
//#endregion
|
|
27
|
+
exports.lint = lint;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { r as EngineResolvedConfig } from "../config-DKEmqMrh.cjs";
|
|
2
|
+
import { r as EngineSystemContext } from "../context-D0_a0kRO.cjs";
|
|
3
|
+
import { ExecutionContext } from "@powerlines/core";
|
|
4
|
+
|
|
5
|
+
//#region src/api/lint.d.ts
|
|
6
|
+
/**
|
|
7
|
+
* Lint the project's source files and report any issues found.
|
|
8
|
+
*
|
|
9
|
+
* @remarks
|
|
10
|
+
* This function serves as the main entry point for the linting process, orchestrating the execution of linting hooks across different environments defined in the project configuration. It ensures that all relevant linting operations are performed in a structured manner, allowing for pre-linting, main linting, and post-linting hooks to be executed at the appropriate stages of the process. The function also utilizes a timer to measure the duration of the linting operation, providing insights into the performance of the linting process.
|
|
11
|
+
*
|
|
12
|
+
* @param context - The execution context for the lint process, which provides access to the project configuration, environment, and utility functions for performing the lint operation. The context is used to manage the state and behavior of the lint process, allowing for hooks to be called at different stages of the lint and for environment-specific configurations to be applied.
|
|
13
|
+
*/
|
|
14
|
+
declare function lint<TResolvedConfig extends EngineResolvedConfig, TSystemContext extends EngineSystemContext>(context: ExecutionContext<TResolvedConfig, TSystemContext>): Promise<void>;
|
|
15
|
+
//#endregion
|
|
16
|
+
export { lint };
|
|
17
|
+
//# sourceMappingURL=lint.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"lint.d.cts","names":[],"sources":["../../src/api/lint.ts"],"mappings":";;;;;;;AAgCA;;;;;;iBAAsB,IAAA,yBACI,oBAAA,yBACD,mBAAA,CAAA,CACvB,OAAA,EAAS,gBAAA,CAAiB,eAAA,EAAiB,cAAA,IAAe,OAAA"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { r as EngineResolvedConfig } from "../config-ByLyzMI0.mjs";
|
|
2
|
+
import { r as EngineSystemContext } from "../context-DcXV6_GL.mjs";
|
|
3
|
+
import { ExecutionContext } from "@powerlines/core";
|
|
4
|
+
|
|
5
|
+
//#region src/api/lint.d.ts
|
|
6
|
+
/**
|
|
7
|
+
* Lint the project's source files and report any issues found.
|
|
8
|
+
*
|
|
9
|
+
* @remarks
|
|
10
|
+
* This function serves as the main entry point for the linting process, orchestrating the execution of linting hooks across different environments defined in the project configuration. It ensures that all relevant linting operations are performed in a structured manner, allowing for pre-linting, main linting, and post-linting hooks to be executed at the appropriate stages of the process. The function also utilizes a timer to measure the duration of the linting operation, providing insights into the performance of the linting process.
|
|
11
|
+
*
|
|
12
|
+
* @param context - The execution context for the lint process, which provides access to the project configuration, environment, and utility functions for performing the lint operation. The context is used to manage the state and behavior of the lint process, allowing for hooks to be called at different stages of the lint and for environment-specific configurations to be applied.
|
|
13
|
+
*/
|
|
14
|
+
declare function lint<TResolvedConfig extends EngineResolvedConfig, TSystemContext extends EngineSystemContext>(context: ExecutionContext<TResolvedConfig, TSystemContext>): Promise<void>;
|
|
15
|
+
//#endregion
|
|
16
|
+
export { lint };
|
|
17
|
+
//# sourceMappingURL=lint.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"lint.d.mts","names":[],"sources":["../../src/api/lint.ts"],"mappings":";;;;;;;AAgCA;;;;;;iBAAsB,IAAA,yBACI,oBAAA,yBACD,mBAAA,CAAA,CACvB,OAAA,EAAS,gBAAA,CAAiB,eAAA,EAAiB,cAAA,IAAe,OAAA"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { prepare } from "./prepare.mjs";
|
|
2
|
+
import { executeEnvironments } from "@powerlines/core/lib/environment";
|
|
3
|
+
|
|
4
|
+
//#region src/api/lint.ts
|
|
5
|
+
/**
|
|
6
|
+
* Lint the project's source files and report any issues found.
|
|
7
|
+
*
|
|
8
|
+
* @remarks
|
|
9
|
+
* This function serves as the main entry point for the linting process, orchestrating the execution of linting hooks across different environments defined in the project configuration. It ensures that all relevant linting operations are performed in a structured manner, allowing for pre-linting, main linting, and post-linting hooks to be executed at the appropriate stages of the process. The function also utilizes a timer to measure the duration of the linting operation, providing insights into the performance of the linting process.
|
|
10
|
+
*
|
|
11
|
+
* @param context - The execution context for the lint process, which provides access to the project configuration, environment, and utility functions for performing the lint operation. The context is used to manage the state and behavior of the lint process, allowing for hooks to be called at different stages of the lint and for environment-specific configurations to be applied.
|
|
12
|
+
*/
|
|
13
|
+
async function lint(context) {
|
|
14
|
+
const timer = context.timer("Linting");
|
|
15
|
+
await prepare(context);
|
|
16
|
+
await executeEnvironments(context, async (env) => {
|
|
17
|
+
await context.callHook("lint", {
|
|
18
|
+
environment: env,
|
|
19
|
+
sequential: false
|
|
20
|
+
});
|
|
21
|
+
});
|
|
22
|
+
timer();
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
//#endregion
|
|
26
|
+
export { lint };
|
|
27
|
+
//# sourceMappingURL=lint.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"lint.mjs","names":[],"sources":["../../src/api/lint.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Powerlines\n\n This code was released as part of the Powerlines project. Powerlines\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/powerlines.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/powerlines\n Documentation: https://docs.stormsoftware.com/projects/powerlines\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport { ExecutionContext } from \"@powerlines/core\";\nimport { executeEnvironments } from \"@powerlines/core/lib/environment\";\nimport { EngineResolvedConfig } from \"../types/config\";\nimport { EngineSystemContext } from \"../types/context\";\nimport { prepare } from \"./prepare\";\n\n/**\n * Lint the project's source files and report any issues found.\n *\n * @remarks\n * This function serves as the main entry point for the linting process, orchestrating the execution of linting hooks across different environments defined in the project configuration. It ensures that all relevant linting operations are performed in a structured manner, allowing for pre-linting, main linting, and post-linting hooks to be executed at the appropriate stages of the process. The function also utilizes a timer to measure the duration of the linting operation, providing insights into the performance of the linting process.\n *\n * @param context - The execution context for the lint process, which provides access to the project configuration, environment, and utility functions for performing the lint operation. The context is used to manage the state and behavior of the lint process, allowing for hooks to be called at different stages of the lint and for environment-specific configurations to be applied.\n */\nexport async function lint<\n TResolvedConfig extends EngineResolvedConfig,\n TSystemContext extends EngineSystemContext\n>(context: ExecutionContext<TResolvedConfig, TSystemContext>) {\n const timer = context.timer(\"Linting\");\n\n await prepare<TResolvedConfig, TSystemContext>(context);\n await executeEnvironments(context, async env => {\n await context.callHook(\"lint\", {\n environment: env,\n sequential: false\n });\n });\n\n timer();\n}\n"],"mappings":";;;;;;;;;;;;AAgCA,eAAsB,KAGpB,SAA4D;CAC5D,MAAM,QAAQ,QAAQ,MAAM,SAAS;CAErC,MAAM,QAAyC,OAAO;CACtD,MAAM,oBAAoB,SAAS,OAAM,QAAO;EAC9C,MAAM,QAAQ,SAAS,QAAQ;GAC7B,aAAa;GACb,YAAY;EACd,CAAC;CACH,CAAC;CAED,MAAM;AACR"}
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
2
|
+
let _powerlines_core_lib_environment = require("@powerlines/core/lib/environment");
|
|
3
|
+
let _powerlines_core_lib_generate_types = require("@powerlines/core/lib/generate-types");
|
|
4
|
+
let _powerlines_core_lib_install_dependencies = require("@powerlines/core/lib/install-dependencies");
|
|
5
|
+
let _powerlines_core_lib_meta = require("@powerlines/core/lib/meta");
|
|
6
|
+
let _powerlines_core_lib_typescript_tsconfig = require("@powerlines/core/lib/typescript/tsconfig");
|
|
7
|
+
let _powerlines_core_lib_utilities_format = require("@powerlines/core/lib/utilities/format");
|
|
8
|
+
let _powerlines_core_plugin_utils = require("@powerlines/core/plugin-utils");
|
|
9
|
+
let _stryke_convert_to_array = require("@stryke/convert/to-array");
|
|
10
|
+
let _stryke_fs_helpers = require("@stryke/fs/helpers");
|
|
11
|
+
let _stryke_type_checks_is_object = require("@stryke/type-checks/is-object");
|
|
12
|
+
|
|
13
|
+
//#region src/api/prepare.ts
|
|
14
|
+
/**
|
|
15
|
+
* Prepare the project
|
|
16
|
+
*
|
|
17
|
+
* @param context - The execution context for the build process, which provides access to the project configuration, environment, and utility functions for performing the build. The context is used to manage the state and behavior of the build process, allowing for hooks to be called at different stages of the build and for environment-specific configurations to be applied.
|
|
18
|
+
*/
|
|
19
|
+
async function prepare(context, skipTypes = false) {
|
|
20
|
+
const timer = context.timer("Preparation");
|
|
21
|
+
await (0, _powerlines_core_lib_environment.executeEnvironments)(context, async (env) => {
|
|
22
|
+
env.debug(`Initializing the processing options for the Powerlines project.`);
|
|
23
|
+
await context.callHook("configResolved", {
|
|
24
|
+
environment: env,
|
|
25
|
+
order: "pre"
|
|
26
|
+
});
|
|
27
|
+
await (0, _powerlines_core_lib_typescript_tsconfig.initializeTsconfig)(env);
|
|
28
|
+
await context.callHook("configResolved", {
|
|
29
|
+
environment: env,
|
|
30
|
+
order: "normal"
|
|
31
|
+
});
|
|
32
|
+
if (env.entry.length > 0) env.debug(`The configuration provided ${(0, _stryke_type_checks_is_object.isObject)(env.config.input) ? Object.keys(env.config.input).length : (0, _stryke_convert_to_array.toArray)(env.config.input).length} entry point(s), Powerlines has found ${env.entry.length} entry files(s) for the ${env.config.title} project${env.entry.length > 0 && env.entry.length < 10 ? `: \n${env.entry.map((entry) => `- ${entry.file}${entry.output ? ` -> ${entry.output}` : ""}`).join(" \n")}` : ""}`);
|
|
33
|
+
else env.warn(`No entry files were found for the ${env.config.title} project. Please ensure this is correct. Powerlines plugins generally require at least one entry point to function properly.`);
|
|
34
|
+
await (0, _powerlines_core_lib_typescript_tsconfig.resolveTsconfig)(env);
|
|
35
|
+
await (0, _powerlines_core_lib_install_dependencies.installDependencies)(env);
|
|
36
|
+
await context.callHook("configResolved", {
|
|
37
|
+
environment: env,
|
|
38
|
+
order: "post"
|
|
39
|
+
});
|
|
40
|
+
env.trace({
|
|
41
|
+
meta: { category: "config" },
|
|
42
|
+
message: `Powerlines configuration after configResolved hook: \n${(0, _powerlines_core_plugin_utils.formatConfig)(env.config)}`
|
|
43
|
+
});
|
|
44
|
+
if (!env.fs.existsSync(env.cachePath)) await (0, _stryke_fs_helpers.createDirectory)(env.cachePath);
|
|
45
|
+
if (!env.fs.existsSync(env.dataPath)) await (0, _stryke_fs_helpers.createDirectory)(env.dataPath);
|
|
46
|
+
await context.callHook("prepare", {
|
|
47
|
+
environment: env,
|
|
48
|
+
order: "pre"
|
|
49
|
+
});
|
|
50
|
+
await context.callHook("prepare", {
|
|
51
|
+
environment: env,
|
|
52
|
+
order: "normal"
|
|
53
|
+
});
|
|
54
|
+
await context.callHook("prepare", {
|
|
55
|
+
environment: env,
|
|
56
|
+
order: "post"
|
|
57
|
+
});
|
|
58
|
+
if (!skipTypes && env.config.output.types !== false) await (0, _powerlines_core_lib_generate_types.handleTypes)(context, env);
|
|
59
|
+
context.debug("Formatting files generated during the prepare step.");
|
|
60
|
+
await Promise.all([(0, _powerlines_core_lib_utilities_format.formatFolder)(env, env.builtinsPath), (0, _powerlines_core_lib_utilities_format.formatFolder)(env, env.entryPath)]);
|
|
61
|
+
await (0, _powerlines_core_lib_meta.writeMetaFile)(env);
|
|
62
|
+
env.persistedMeta = env.meta;
|
|
63
|
+
});
|
|
64
|
+
timer();
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
//#endregion
|
|
68
|
+
exports.prepare = prepare;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { r as EngineResolvedConfig } from "../config-DKEmqMrh.cjs";
|
|
2
|
+
import { r as EngineSystemContext } from "../context-D0_a0kRO.cjs";
|
|
3
|
+
import { ExecutionContext } from "@powerlines/core";
|
|
4
|
+
|
|
5
|
+
//#region src/api/prepare.d.ts
|
|
6
|
+
/**
|
|
7
|
+
* Prepare the project
|
|
8
|
+
*
|
|
9
|
+
* @param context - The execution context for the build process, which provides access to the project configuration, environment, and utility functions for performing the build. The context is used to manage the state and behavior of the build process, allowing for hooks to be called at different stages of the build and for environment-specific configurations to be applied.
|
|
10
|
+
*/
|
|
11
|
+
declare function prepare<TResolvedConfig extends EngineResolvedConfig, TSystemContext extends EngineSystemContext>(context: ExecutionContext<TResolvedConfig, TSystemContext>, skipTypes?: boolean): Promise<void>;
|
|
12
|
+
//#endregion
|
|
13
|
+
export { prepare };
|
|
14
|
+
//# sourceMappingURL=prepare.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"prepare.d.cts","names":[],"sources":["../../src/api/prepare.ts"],"mappings":";;;;;;;AAwCA;;;iBAAsB,OAAA,yBACI,oBAAA,yBACD,mBAAA,CAAA,CAEvB,OAAA,EAAS,gBAAA,CAAiB,eAAA,EAAiB,cAAA,GAC3C,SAAA,aAAiB,OAAA"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { r as EngineResolvedConfig } from "../config-ByLyzMI0.mjs";
|
|
2
|
+
import { r as EngineSystemContext } from "../context-DcXV6_GL.mjs";
|
|
3
|
+
import { ExecutionContext } from "@powerlines/core";
|
|
4
|
+
|
|
5
|
+
//#region src/api/prepare.d.ts
|
|
6
|
+
/**
|
|
7
|
+
* Prepare the project
|
|
8
|
+
*
|
|
9
|
+
* @param context - The execution context for the build process, which provides access to the project configuration, environment, and utility functions for performing the build. The context is used to manage the state and behavior of the build process, allowing for hooks to be called at different stages of the build and for environment-specific configurations to be applied.
|
|
10
|
+
*/
|
|
11
|
+
declare function prepare<TResolvedConfig extends EngineResolvedConfig, TSystemContext extends EngineSystemContext>(context: ExecutionContext<TResolvedConfig, TSystemContext>, skipTypes?: boolean): Promise<void>;
|
|
12
|
+
//#endregion
|
|
13
|
+
export { prepare };
|
|
14
|
+
//# sourceMappingURL=prepare.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"prepare.d.mts","names":[],"sources":["../../src/api/prepare.ts"],"mappings":";;;;;;;AAwCA;;;iBAAsB,OAAA,yBACI,oBAAA,yBACD,mBAAA,CAAA,CAEvB,OAAA,EAAS,gBAAA,CAAiB,eAAA,EAAiB,cAAA,GAC3C,SAAA,aAAiB,OAAA"}
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import { executeEnvironments } from "@powerlines/core/lib/environment";
|
|
2
|
+
import { handleTypes } from "@powerlines/core/lib/generate-types";
|
|
3
|
+
import { installDependencies } from "@powerlines/core/lib/install-dependencies";
|
|
4
|
+
import { writeMetaFile } from "@powerlines/core/lib/meta";
|
|
5
|
+
import { initializeTsconfig, resolveTsconfig } from "@powerlines/core/lib/typescript/tsconfig";
|
|
6
|
+
import { formatFolder } from "@powerlines/core/lib/utilities/format";
|
|
7
|
+
import { formatConfig } from "@powerlines/core/plugin-utils";
|
|
8
|
+
import { toArray } from "@stryke/convert/to-array";
|
|
9
|
+
import { createDirectory } from "@stryke/fs/helpers";
|
|
10
|
+
import { isObject } from "@stryke/type-checks/is-object";
|
|
11
|
+
|
|
12
|
+
//#region src/api/prepare.ts
|
|
13
|
+
/**
|
|
14
|
+
* Prepare the project
|
|
15
|
+
*
|
|
16
|
+
* @param context - The execution context for the build process, which provides access to the project configuration, environment, and utility functions for performing the build. The context is used to manage the state and behavior of the build process, allowing for hooks to be called at different stages of the build and for environment-specific configurations to be applied.
|
|
17
|
+
*/
|
|
18
|
+
async function prepare(context, skipTypes = false) {
|
|
19
|
+
const timer = context.timer("Preparation");
|
|
20
|
+
await executeEnvironments(context, async (env) => {
|
|
21
|
+
env.debug(`Initializing the processing options for the Powerlines project.`);
|
|
22
|
+
await context.callHook("configResolved", {
|
|
23
|
+
environment: env,
|
|
24
|
+
order: "pre"
|
|
25
|
+
});
|
|
26
|
+
await initializeTsconfig(env);
|
|
27
|
+
await context.callHook("configResolved", {
|
|
28
|
+
environment: env,
|
|
29
|
+
order: "normal"
|
|
30
|
+
});
|
|
31
|
+
if (env.entry.length > 0) env.debug(`The configuration provided ${isObject(env.config.input) ? Object.keys(env.config.input).length : toArray(env.config.input).length} entry point(s), Powerlines has found ${env.entry.length} entry files(s) for the ${env.config.title} project${env.entry.length > 0 && env.entry.length < 10 ? `: \n${env.entry.map((entry) => `- ${entry.file}${entry.output ? ` -> ${entry.output}` : ""}`).join(" \n")}` : ""}`);
|
|
32
|
+
else env.warn(`No entry files were found for the ${env.config.title} project. Please ensure this is correct. Powerlines plugins generally require at least one entry point to function properly.`);
|
|
33
|
+
await resolveTsconfig(env);
|
|
34
|
+
await installDependencies(env);
|
|
35
|
+
await context.callHook("configResolved", {
|
|
36
|
+
environment: env,
|
|
37
|
+
order: "post"
|
|
38
|
+
});
|
|
39
|
+
env.trace({
|
|
40
|
+
meta: { category: "config" },
|
|
41
|
+
message: `Powerlines configuration after configResolved hook: \n${formatConfig(env.config)}`
|
|
42
|
+
});
|
|
43
|
+
if (!env.fs.existsSync(env.cachePath)) await createDirectory(env.cachePath);
|
|
44
|
+
if (!env.fs.existsSync(env.dataPath)) await createDirectory(env.dataPath);
|
|
45
|
+
await context.callHook("prepare", {
|
|
46
|
+
environment: env,
|
|
47
|
+
order: "pre"
|
|
48
|
+
});
|
|
49
|
+
await context.callHook("prepare", {
|
|
50
|
+
environment: env,
|
|
51
|
+
order: "normal"
|
|
52
|
+
});
|
|
53
|
+
await context.callHook("prepare", {
|
|
54
|
+
environment: env,
|
|
55
|
+
order: "post"
|
|
56
|
+
});
|
|
57
|
+
if (!skipTypes && env.config.output.types !== false) await handleTypes(context, env);
|
|
58
|
+
context.debug("Formatting files generated during the prepare step.");
|
|
59
|
+
await Promise.all([formatFolder(env, env.builtinsPath), formatFolder(env, env.entryPath)]);
|
|
60
|
+
await writeMetaFile(env);
|
|
61
|
+
env.persistedMeta = env.meta;
|
|
62
|
+
});
|
|
63
|
+
timer();
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
//#endregion
|
|
67
|
+
export { prepare };
|
|
68
|
+
//# sourceMappingURL=prepare.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"prepare.mjs","names":[],"sources":["../../src/api/prepare.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Powerlines\n\n This code was released as part of the Powerlines project. Powerlines\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/powerlines.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/powerlines\n Documentation: https://docs.stormsoftware.com/projects/powerlines\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport type { ExecutionContext } from \"@powerlines/core\";\nimport { executeEnvironments } from \"@powerlines/core/lib/environment\";\nimport { handleTypes } from \"@powerlines/core/lib/generate-types\";\nimport { installDependencies } from \"@powerlines/core/lib/install-dependencies\";\nimport { writeMetaFile } from \"@powerlines/core/lib/meta\";\nimport {\n initializeTsconfig,\n resolveTsconfig\n} from \"@powerlines/core/lib/typescript/tsconfig\";\nimport { formatFolder } from \"@powerlines/core/lib/utilities/format\";\nimport { formatConfig } from \"@powerlines/core/plugin-utils\";\nimport { toArray } from \"@stryke/convert/to-array\";\nimport { createDirectory } from \"@stryke/fs/helpers\";\nimport { isObject } from \"@stryke/type-checks/is-object\";\nimport { EngineResolvedConfig } from \"../types/config\";\nimport { EngineSystemContext } from \"../types/context\";\n\n/**\n * Prepare the project\n *\n * @param context - The execution context for the build process, which provides access to the project configuration, environment, and utility functions for performing the build. The context is used to manage the state and behavior of the build process, allowing for hooks to be called at different stages of the build and for environment-specific configurations to be applied.\n */\nexport async function prepare<\n TResolvedConfig extends EngineResolvedConfig,\n TSystemContext extends EngineSystemContext\n>(\n context: ExecutionContext<TResolvedConfig, TSystemContext>,\n skipTypes = false\n) {\n const timer = context.timer(\"Preparation\");\n\n await executeEnvironments(context, async env => {\n env.debug(\n `Initializing the processing options for the Powerlines project.`\n );\n\n await context.callHook(\"configResolved\", {\n environment: env,\n order: \"pre\"\n });\n\n await initializeTsconfig<TResolvedConfig, TSystemContext>(env);\n\n await context.callHook(\"configResolved\", {\n environment: env,\n order: \"normal\"\n });\n\n if (env.entry.length > 0) {\n env.debug(\n `The configuration provided ${\n isObject(env.config.input)\n ? Object.keys(env.config.input).length\n : toArray(env.config.input).length\n } entry point(s), Powerlines has found ${\n env.entry.length\n } entry files(s) for the ${env.config.title} project${\n env.entry.length > 0 && env.entry.length < 10\n ? `: \\n${env.entry\n .map(\n entry =>\n `- ${entry.file}${\n entry.output ? ` -> ${entry.output}` : \"\"\n }`\n )\n .join(\" \\n\")}`\n : \"\"\n }`\n );\n } else {\n env.warn(\n `No entry files were found for the ${\n env.config.title\n } project. Please ensure this is correct. Powerlines plugins generally require at least one entry point to function properly.`\n );\n }\n\n await resolveTsconfig<TResolvedConfig, TSystemContext>(env);\n await installDependencies(env);\n\n await context.callHook(\"configResolved\", {\n environment: env,\n order: \"post\"\n });\n\n env.trace({\n meta: {\n category: \"config\"\n },\n message: `Powerlines configuration after configResolved hook: \\n${formatConfig(\n env.config\n )}`\n });\n\n if (!env.fs.existsSync(env.cachePath)) {\n await createDirectory(env.cachePath);\n }\n\n if (!env.fs.existsSync(env.dataPath)) {\n await createDirectory(env.dataPath);\n }\n\n await context.callHook(\"prepare\", {\n environment: env,\n order: \"pre\"\n });\n await context.callHook(\"prepare\", {\n environment: env,\n order: \"normal\"\n });\n\n await context.callHook(\"prepare\", {\n environment: env,\n order: \"post\"\n });\n\n if (!skipTypes && env.config.output.types !== false) {\n await handleTypes(context, env);\n }\n\n context.debug(\"Formatting files generated during the prepare step.\");\n\n await Promise.all([\n formatFolder(env, env.builtinsPath),\n formatFolder(env, env.entryPath)\n ]);\n\n await writeMetaFile(env);\n env.persistedMeta = env.meta;\n });\n\n timer();\n}\n"],"mappings":";;;;;;;;;;;;;;;;;AAwCA,eAAsB,QAIpB,SACA,YAAY,OACZ;CACA,MAAM,QAAQ,QAAQ,MAAM,aAAa;CAEzC,MAAM,oBAAoB,SAAS,OAAM,QAAO;EAC9C,IAAI,MACF,iEACF;EAEA,MAAM,QAAQ,SAAS,kBAAkB;GACvC,aAAa;GACb,OAAO;EACT,CAAC;EAED,MAAM,mBAAoD,GAAG;EAE7D,MAAM,QAAQ,SAAS,kBAAkB;GACvC,aAAa;GACb,OAAO;EACT,CAAC;EAED,IAAI,IAAI,MAAM,SAAS,GACrB,IAAI,MACF,8BACE,SAAS,IAAI,OAAO,KAAK,IACrB,OAAO,KAAK,IAAI,OAAO,KAAK,EAAE,SAC9B,QAAQ,IAAI,OAAO,KAAK,EAAE,OAC/B,wCACC,IAAI,MAAM,OACX,0BAA0B,IAAI,OAAO,MAAM,UAC1C,IAAI,MAAM,SAAS,KAAK,IAAI,MAAM,SAAS,KACvC,OAAO,IAAI,MACR,KACC,UACE,KAAK,MAAM,OACT,MAAM,SAAS,OAAO,MAAM,WAAW,IAE7C,EACC,KAAK,KAAK,MACb,IAER;OAEA,IAAI,KACF,qCACE,IAAI,OAAO,MACZ,6HACH;EAGF,MAAM,gBAAiD,GAAG;EAC1D,MAAM,oBAAoB,GAAG;EAE7B,MAAM,QAAQ,SAAS,kBAAkB;GACvC,aAAa;GACb,OAAO;EACT,CAAC;EAED,IAAI,MAAM;GACR,MAAM,EACJ,UAAU,SACZ;GACA,SAAS,yDAAyD,aAChE,IAAI,MACN;EACF,CAAC;EAED,IAAI,CAAC,IAAI,GAAG,WAAW,IAAI,SAAS,GAClC,MAAM,gBAAgB,IAAI,SAAS;EAGrC,IAAI,CAAC,IAAI,GAAG,WAAW,IAAI,QAAQ,GACjC,MAAM,gBAAgB,IAAI,QAAQ;EAGpC,MAAM,QAAQ,SAAS,WAAW;GAChC,aAAa;GACb,OAAO;EACT,CAAC;EACD,MAAM,QAAQ,SAAS,WAAW;GAChC,aAAa;GACb,OAAO;EACT,CAAC;EAED,MAAM,QAAQ,SAAS,WAAW;GAChC,aAAa;GACb,OAAO;EACT,CAAC;EAED,IAAI,CAAC,aAAa,IAAI,OAAO,OAAO,UAAU,OAC5C,MAAM,YAAY,SAAS,GAAG;EAGhC,QAAQ,MAAM,qDAAqD;EAEnE,MAAM,QAAQ,IAAI,CAChB,aAAa,KAAK,IAAI,YAAY,GAClC,aAAa,KAAK,IAAI,SAAS,CACjC,CAAC;EAED,MAAM,cAAc,GAAG;EACvB,IAAI,gBAAgB,IAAI;CAC1B,CAAC;CAED,MAAM;AACR"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
2
|
+
const require_api_prepare = require('./prepare.cjs');
|
|
3
|
+
let _powerlines_core_lib_environment = require("@powerlines/core/lib/environment");
|
|
4
|
+
|
|
5
|
+
//#region src/api/test.ts
|
|
6
|
+
/**
|
|
7
|
+
* Test the project's source files and report any issues found.
|
|
8
|
+
*
|
|
9
|
+
* @remarks
|
|
10
|
+
* This function serves as the main entry point for the testing process, orchestrating the execution of testing hooks across different environments defined in the project configuration. It ensures that all relevant testing operations are performed in a structured manner, allowing for pre-testing, main testing, and post-testing hooks to be executed at the appropriate stages of the process. The function also utilizes a timer to measure the duration of the testing operation, providing insights into the performance of the testing process.
|
|
11
|
+
*
|
|
12
|
+
* @param context - The execution context for the test process, which provides access to the project configuration, environment, and utility functions for performing the test operation. The context is used to manage the state and behavior of the test process, allowing for hooks to be called at different stages of the test and for environment-specific configurations to be applied.
|
|
13
|
+
*/
|
|
14
|
+
async function test(context) {
|
|
15
|
+
const timer = context.timer("Testing");
|
|
16
|
+
await require_api_prepare.prepare(context);
|
|
17
|
+
await (0, _powerlines_core_lib_environment.executeEnvironments)(context, async (env) => {
|
|
18
|
+
await context.callHook("test", {
|
|
19
|
+
environment: env,
|
|
20
|
+
sequential: false
|
|
21
|
+
});
|
|
22
|
+
});
|
|
23
|
+
timer();
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
//#endregion
|
|
27
|
+
exports.test = test;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { r as EngineResolvedConfig } from "../config-DKEmqMrh.cjs";
|
|
2
|
+
import { r as EngineSystemContext } from "../context-D0_a0kRO.cjs";
|
|
3
|
+
import { ExecutionContext } from "@powerlines/core";
|
|
4
|
+
|
|
5
|
+
//#region src/api/test.d.ts
|
|
6
|
+
/**
|
|
7
|
+
* Test the project's source files and report any issues found.
|
|
8
|
+
*
|
|
9
|
+
* @remarks
|
|
10
|
+
* This function serves as the main entry point for the testing process, orchestrating the execution of testing hooks across different environments defined in the project configuration. It ensures that all relevant testing operations are performed in a structured manner, allowing for pre-testing, main testing, and post-testing hooks to be executed at the appropriate stages of the process. The function also utilizes a timer to measure the duration of the testing operation, providing insights into the performance of the testing process.
|
|
11
|
+
*
|
|
12
|
+
* @param context - The execution context for the test process, which provides access to the project configuration, environment, and utility functions for performing the test operation. The context is used to manage the state and behavior of the test process, allowing for hooks to be called at different stages of the test and for environment-specific configurations to be applied.
|
|
13
|
+
*/
|
|
14
|
+
declare function test<TResolvedConfig extends EngineResolvedConfig, TSystemContext extends EngineSystemContext>(context: ExecutionContext<TResolvedConfig, TSystemContext>): Promise<void>;
|
|
15
|
+
//#endregion
|
|
16
|
+
export { test };
|
|
17
|
+
//# sourceMappingURL=test.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"test.d.cts","names":[],"sources":["../../src/api/test.ts"],"mappings":";;;;;;;AAgCA;;;;;;iBAAsB,IAAA,yBACI,oBAAA,yBACD,mBAAA,CAAA,CACvB,OAAA,EAAS,gBAAA,CAAiB,eAAA,EAAiB,cAAA,IAAe,OAAA"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { r as EngineResolvedConfig } from "../config-ByLyzMI0.mjs";
|
|
2
|
+
import { r as EngineSystemContext } from "../context-DcXV6_GL.mjs";
|
|
3
|
+
import { ExecutionContext } from "@powerlines/core";
|
|
4
|
+
|
|
5
|
+
//#region src/api/test.d.ts
|
|
6
|
+
/**
|
|
7
|
+
* Test the project's source files and report any issues found.
|
|
8
|
+
*
|
|
9
|
+
* @remarks
|
|
10
|
+
* This function serves as the main entry point for the testing process, orchestrating the execution of testing hooks across different environments defined in the project configuration. It ensures that all relevant testing operations are performed in a structured manner, allowing for pre-testing, main testing, and post-testing hooks to be executed at the appropriate stages of the process. The function also utilizes a timer to measure the duration of the testing operation, providing insights into the performance of the testing process.
|
|
11
|
+
*
|
|
12
|
+
* @param context - The execution context for the test process, which provides access to the project configuration, environment, and utility functions for performing the test operation. The context is used to manage the state and behavior of the test process, allowing for hooks to be called at different stages of the test and for environment-specific configurations to be applied.
|
|
13
|
+
*/
|
|
14
|
+
declare function test<TResolvedConfig extends EngineResolvedConfig, TSystemContext extends EngineSystemContext>(context: ExecutionContext<TResolvedConfig, TSystemContext>): Promise<void>;
|
|
15
|
+
//#endregion
|
|
16
|
+
export { test };
|
|
17
|
+
//# sourceMappingURL=test.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"test.d.mts","names":[],"sources":["../../src/api/test.ts"],"mappings":";;;;;;;AAgCA;;;;;;iBAAsB,IAAA,yBACI,oBAAA,yBACD,mBAAA,CAAA,CACvB,OAAA,EAAS,gBAAA,CAAiB,eAAA,EAAiB,cAAA,IAAe,OAAA"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { prepare } from "./prepare.mjs";
|
|
2
|
+
import { executeEnvironments } from "@powerlines/core/lib/environment";
|
|
3
|
+
|
|
4
|
+
//#region src/api/test.ts
|
|
5
|
+
/**
|
|
6
|
+
* Test the project's source files and report any issues found.
|
|
7
|
+
*
|
|
8
|
+
* @remarks
|
|
9
|
+
* This function serves as the main entry point for the testing process, orchestrating the execution of testing hooks across different environments defined in the project configuration. It ensures that all relevant testing operations are performed in a structured manner, allowing for pre-testing, main testing, and post-testing hooks to be executed at the appropriate stages of the process. The function also utilizes a timer to measure the duration of the testing operation, providing insights into the performance of the testing process.
|
|
10
|
+
*
|
|
11
|
+
* @param context - The execution context for the test process, which provides access to the project configuration, environment, and utility functions for performing the test operation. The context is used to manage the state and behavior of the test process, allowing for hooks to be called at different stages of the test and for environment-specific configurations to be applied.
|
|
12
|
+
*/
|
|
13
|
+
async function test(context) {
|
|
14
|
+
const timer = context.timer("Testing");
|
|
15
|
+
await prepare(context);
|
|
16
|
+
await executeEnvironments(context, async (env) => {
|
|
17
|
+
await context.callHook("test", {
|
|
18
|
+
environment: env,
|
|
19
|
+
sequential: false
|
|
20
|
+
});
|
|
21
|
+
});
|
|
22
|
+
timer();
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
//#endregion
|
|
26
|
+
export { test };
|
|
27
|
+
//# sourceMappingURL=test.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"test.mjs","names":[],"sources":["../../src/api/test.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Powerlines\n\n This code was released as part of the Powerlines project. Powerlines\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/powerlines.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/powerlines\n Documentation: https://docs.stormsoftware.com/projects/powerlines\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport { ExecutionContext } from \"@powerlines/core\";\nimport { executeEnvironments } from \"@powerlines/core/lib/environment\";\nimport { EngineResolvedConfig } from \"../types/config\";\nimport { EngineSystemContext } from \"../types/context\";\nimport { prepare } from \"./prepare\";\n\n/**\n * Test the project's source files and report any issues found.\n *\n * @remarks\n * This function serves as the main entry point for the testing process, orchestrating the execution of testing hooks across different environments defined in the project configuration. It ensures that all relevant testing operations are performed in a structured manner, allowing for pre-testing, main testing, and post-testing hooks to be executed at the appropriate stages of the process. The function also utilizes a timer to measure the duration of the testing operation, providing insights into the performance of the testing process.\n *\n * @param context - The execution context for the test process, which provides access to the project configuration, environment, and utility functions for performing the test operation. The context is used to manage the state and behavior of the test process, allowing for hooks to be called at different stages of the test and for environment-specific configurations to be applied.\n */\nexport async function test<\n TResolvedConfig extends EngineResolvedConfig,\n TSystemContext extends EngineSystemContext\n>(context: ExecutionContext<TResolvedConfig, TSystemContext>) {\n const timer = context.timer(\"Testing\");\n\n await prepare(context);\n await executeEnvironments(context, async env => {\n await context.callHook(\"test\", {\n environment: env,\n sequential: false\n });\n });\n\n timer();\n}\n"],"mappings":";;;;;;;;;;;;AAgCA,eAAsB,KAGpB,SAA4D;CAC5D,MAAM,QAAQ,QAAQ,MAAM,SAAS;CAErC,MAAM,QAAQ,OAAO;CACrB,MAAM,oBAAoB,SAAS,OAAM,QAAO;EAC9C,MAAM,QAAQ,SAAS,QAAQ;GAC7B,aAAa;GACb,YAAY;EACd,CAAC;CACH,CAAC;CAED,MAAM;AACR"}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
2
|
+
const require_api_prepare = require('./prepare.cjs');
|
|
3
|
+
let _powerlines_core_lib_environment = require("@powerlines/core/lib/environment");
|
|
4
|
+
let _powerlines_core_lib_generate_types = require("@powerlines/core/lib/generate-types");
|
|
5
|
+
let _powerlines_core_lib_install_dependencies = require("@powerlines/core/lib/install-dependencies");
|
|
6
|
+
let _powerlines_core_lib_meta = require("@powerlines/core/lib/meta");
|
|
7
|
+
let _powerlines_core_lib_typescript_tsconfig = require("@powerlines/core/lib/typescript/tsconfig");
|
|
8
|
+
let _powerlines_core_lib_utilities_format = require("@powerlines/core/lib/utilities/format");
|
|
9
|
+
let _stryke_convert_to_array = require("@stryke/convert/to-array");
|
|
10
|
+
let _stryke_fs_helpers = require("@stryke/fs/helpers");
|
|
11
|
+
let _stryke_type_checks_is_object = require("@stryke/type-checks/is-object");
|
|
12
|
+
let _storm_software_config_tools_logger = require("@storm-software/config-tools/logger");
|
|
13
|
+
let _stryke_helpers_omit = require("@stryke/helpers/omit");
|
|
14
|
+
let _stryke_type_checks_is_set_object = require("@stryke/type-checks/is-set-object");
|
|
15
|
+
|
|
16
|
+
//#region src/api/types.ts
|
|
17
|
+
/**
|
|
18
|
+
* Generate runtime types for the Powerlines project.
|
|
19
|
+
*
|
|
20
|
+
* @remarks
|
|
21
|
+
* This function is responsible for generating TypeScript declaration files based on the project's configuration and environment. It executes hooks at various stages of the type generation process, allowing for customization and extension by plugins. The generated types are formatted and written to the appropriate location in the project's file system, ensuring that they are available for use by other parts of the Powerlines system and by end-users of the project.
|
|
22
|
+
*
|
|
23
|
+
* @param context - The execution context for the build process, which provides access to the project configuration, environment, and utility functions for performing the build. The context is used to manage the state and behavior of the build process, allowing for hooks to be called at different stages of the build and for environment-specific configurations to be applied.
|
|
24
|
+
*/
|
|
25
|
+
async function types(context) {
|
|
26
|
+
const timer = context.timer("Type Generation");
|
|
27
|
+
context.debug(" Aggregating configuration options for the Powerlines project");
|
|
28
|
+
await (0, _powerlines_core_lib_environment.executeEnvironments)(context, async (env) => {
|
|
29
|
+
env.debug(`Initializing the processing options for the Powerlines project.`);
|
|
30
|
+
await context.callHook("configResolved", {
|
|
31
|
+
environment: env,
|
|
32
|
+
order: "pre"
|
|
33
|
+
});
|
|
34
|
+
await (0, _powerlines_core_lib_typescript_tsconfig.initializeTsconfig)(env);
|
|
35
|
+
await context.callHook("configResolved", {
|
|
36
|
+
environment: env,
|
|
37
|
+
order: "normal"
|
|
38
|
+
});
|
|
39
|
+
if (env.entry.length > 0) env.debug(`The configuration provided ${(0, _stryke_type_checks_is_object.isObject)(env.config.input) ? Object.keys(env.config.input).length : (0, _stryke_convert_to_array.toArray)(env.config.input).length} entry point(s), Powerlines has found ${env.entry.length} entry files(s) for the ${env.config.title} project${env.entry.length > 0 && env.entry.length < 10 ? `: \n${env.entry.map((entry) => `- ${entry.file}${entry.output ? ` -> ${entry.output}` : ""}`).join(" \n")}` : ""}`);
|
|
40
|
+
else env.warn(`No entry files were found for the ${env.config.title} project. Please ensure this is correct. Powerlines plugins generally require at least one entry point to function properly.`);
|
|
41
|
+
await (0, _powerlines_core_lib_typescript_tsconfig.resolveTsconfig)(env);
|
|
42
|
+
await (0, _powerlines_core_lib_install_dependencies.installDependencies)(env);
|
|
43
|
+
await context.callHook("configResolved", {
|
|
44
|
+
environment: env,
|
|
45
|
+
order: "post"
|
|
46
|
+
});
|
|
47
|
+
context.trace(`Powerlines configuration has been resolved: \n\n${(0, _storm_software_config_tools_logger.formatLogMessage)({
|
|
48
|
+
...env.config,
|
|
49
|
+
userConfig: (0, _stryke_type_checks_is_set_object.isSetObject)(env.config.userConfig) ? (0, _stryke_helpers_omit.omit)(env.config.userConfig, ["plugins"]) : void 0,
|
|
50
|
+
inlineConfig: (0, _stryke_type_checks_is_set_object.isSetObject)(env.config.inlineConfig) ? env.config.inlineConfig : void 0,
|
|
51
|
+
plugins: env.plugins.map((plugin) => plugin.name)
|
|
52
|
+
})}`);
|
|
53
|
+
if (!env.fs.existsSync(env.cachePath)) await (0, _stryke_fs_helpers.createDirectory)(env.cachePath);
|
|
54
|
+
if (!env.fs.existsSync(env.dataPath)) await (0, _stryke_fs_helpers.createDirectory)(env.dataPath);
|
|
55
|
+
if (env.config.skipCache === true || env.persistedMeta?.checksum !== env.meta.checksum) env.debug(`Using previously prepared files as the meta checksum has not changed.`);
|
|
56
|
+
else {
|
|
57
|
+
env.info(`Running \`prepare\` command as the meta checksum has changed since the last run.`);
|
|
58
|
+
await require_api_prepare.prepare(context, true);
|
|
59
|
+
}
|
|
60
|
+
await (0, _powerlines_core_lib_generate_types.handleTypes)(context, env);
|
|
61
|
+
context.debug("Formatting files generated during the types step.");
|
|
62
|
+
await (0, _powerlines_core_lib_utilities_format.format)(env, env.typesPath, await env.fs.read(env.typesPath) ?? "");
|
|
63
|
+
await (0, _powerlines_core_lib_meta.writeMetaFile)(env);
|
|
64
|
+
env.persistedMeta = env.meta;
|
|
65
|
+
});
|
|
66
|
+
timer();
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
//#endregion
|
|
70
|
+
exports.types = types;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { r as EngineResolvedConfig } from "../config-DKEmqMrh.cjs";
|
|
2
|
+
import { r as EngineSystemContext } from "../context-D0_a0kRO.cjs";
|
|
3
|
+
import { ExecutionContext } from "@powerlines/core/types/context";
|
|
4
|
+
|
|
5
|
+
//#region src/api/types.d.ts
|
|
6
|
+
/**
|
|
7
|
+
* Generate runtime types for the Powerlines project.
|
|
8
|
+
*
|
|
9
|
+
* @remarks
|
|
10
|
+
* This function is responsible for generating TypeScript declaration files based on the project's configuration and environment. It executes hooks at various stages of the type generation process, allowing for customization and extension by plugins. The generated types are formatted and written to the appropriate location in the project's file system, ensuring that they are available for use by other parts of the Powerlines system and by end-users of the project.
|
|
11
|
+
*
|
|
12
|
+
* @param context - The execution context for the build process, which provides access to the project configuration, environment, and utility functions for performing the build. The context is used to manage the state and behavior of the build process, allowing for hooks to be called at different stages of the build and for environment-specific configurations to be applied.
|
|
13
|
+
*/
|
|
14
|
+
declare function types<TResolvedConfig extends EngineResolvedConfig, TSystemContext extends EngineSystemContext>(context: ExecutionContext<TResolvedConfig, TSystemContext>): Promise<void>;
|
|
15
|
+
//#endregion
|
|
16
|
+
export { types };
|
|
17
|
+
//# sourceMappingURL=types.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.cts","names":[],"sources":["../../src/api/types.ts"],"mappings":";;;;;;;AA8CA;;;;;;iBAAsB,KAAA,yBACI,oBAAA,yBACD,mBAAA,CAAA,CACvB,OAAA,EAAS,gBAAA,CAAiB,eAAA,EAAiB,cAAA,IAAe,OAAA"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { r as EngineResolvedConfig } from "../config-ByLyzMI0.mjs";
|
|
2
|
+
import { r as EngineSystemContext } from "../context-DcXV6_GL.mjs";
|
|
3
|
+
import { ExecutionContext } from "@powerlines/core/types/context";
|
|
4
|
+
|
|
5
|
+
//#region src/api/types.d.ts
|
|
6
|
+
/**
|
|
7
|
+
* Generate runtime types for the Powerlines project.
|
|
8
|
+
*
|
|
9
|
+
* @remarks
|
|
10
|
+
* This function is responsible for generating TypeScript declaration files based on the project's configuration and environment. It executes hooks at various stages of the type generation process, allowing for customization and extension by plugins. The generated types are formatted and written to the appropriate location in the project's file system, ensuring that they are available for use by other parts of the Powerlines system and by end-users of the project.
|
|
11
|
+
*
|
|
12
|
+
* @param context - The execution context for the build process, which provides access to the project configuration, environment, and utility functions for performing the build. The context is used to manage the state and behavior of the build process, allowing for hooks to be called at different stages of the build and for environment-specific configurations to be applied.
|
|
13
|
+
*/
|
|
14
|
+
declare function types<TResolvedConfig extends EngineResolvedConfig, TSystemContext extends EngineSystemContext>(context: ExecutionContext<TResolvedConfig, TSystemContext>): Promise<void>;
|
|
15
|
+
//#endregion
|
|
16
|
+
export { types };
|
|
17
|
+
//# sourceMappingURL=types.d.mts.map
|