powerlines 0.42.41 → 0.43.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.
Files changed (125) hide show
  1. package/dist/{chunk-AIJqnxB6.cjs → _virtual/_rolldown/runtime.cjs} +1 -32
  2. package/dist/{chunk-CtajNgzt.mjs → _virtual/_rolldown/runtime.mjs} +1 -1
  3. package/dist/api.cjs +10 -0
  4. package/dist/api.d.cts +2 -0
  5. package/dist/api.d.mts +2 -0
  6. package/dist/api.mjs +3 -0
  7. package/dist/config.cjs +0 -12
  8. package/dist/config.mjs +1 -10
  9. package/dist/constants.cjs +0 -12
  10. package/dist/constants.mjs +1 -10
  11. package/dist/context.cjs +9 -0
  12. package/dist/context.d.cts +1 -0
  13. package/dist/context.d.mts +1 -0
  14. package/dist/context.mjs +3 -0
  15. package/dist/engine.cjs +30 -0
  16. package/dist/engine.d.cts +24 -0
  17. package/dist/engine.d.cts.map +1 -0
  18. package/dist/engine.d.mts +24 -0
  19. package/dist/engine.d.mts.map +1 -0
  20. package/dist/engine.mjs +29 -0
  21. package/dist/engine.mjs.map +1 -0
  22. package/dist/esbuild.cjs +2 -2
  23. package/dist/esbuild.mjs.map +1 -1
  24. package/dist/farm.cjs +1 -1
  25. package/dist/index.cjs +24 -16
  26. package/dist/index.d.cts +13 -260
  27. package/dist/index.d.cts.map +1 -1
  28. package/dist/index.d.mts +13 -260
  29. package/dist/index.d.mts.map +1 -1
  30. package/dist/index.mjs +14 -8
  31. package/dist/index.mjs.map +1 -1
  32. package/dist/nuxt.cjs +4 -4
  33. package/dist/nuxt.d.cts +1 -1
  34. package/dist/nuxt.d.mts +1 -1
  35. package/dist/nuxt.mjs +1 -1
  36. package/dist/package.cjs +18 -0
  37. package/dist/package.mjs +7 -0
  38. package/dist/package.mjs.map +1 -0
  39. package/dist/plugin-utils.cjs +0 -12
  40. package/dist/plugin-utils.mjs +1 -10
  41. package/dist/rolldown.cjs +2 -2
  42. package/dist/rollup.cjs +2 -2
  43. package/dist/rspack.cjs +2 -2
  44. package/dist/schemas.cjs +9 -0
  45. package/dist/schemas.d.cts +1 -0
  46. package/dist/schemas.d.mts +1 -0
  47. package/dist/schemas.mjs +3 -0
  48. package/dist/storage.cjs +9 -0
  49. package/dist/storage.d.cts +1 -0
  50. package/dist/storage.d.mts +1 -0
  51. package/dist/storage.mjs +3 -0
  52. package/dist/tsdown.cjs +3 -3
  53. package/dist/tsdown.mjs +1 -1
  54. package/dist/tsup.cjs +2 -2
  55. package/dist/types.cjs +0 -0
  56. package/dist/types.d.cts +8 -0
  57. package/dist/types.d.cts.map +1 -0
  58. package/dist/types.d.mts +8 -0
  59. package/dist/types.d.mts.map +1 -0
  60. package/dist/types.mjs +1 -0
  61. package/dist/typescript.cjs +9 -0
  62. package/dist/typescript.d.cts +1 -0
  63. package/dist/typescript.d.mts +1 -0
  64. package/dist/typescript.mjs +3 -0
  65. package/dist/unbuild.cjs +17 -0
  66. package/dist/unbuild.d.cts +2 -0
  67. package/dist/unbuild.d.mts +2 -0
  68. package/dist/unbuild.mjs +3 -0
  69. package/dist/unloader.cjs +1 -1
  70. package/dist/unplugin.cjs +13 -14
  71. package/dist/unplugin.d.cts +3 -2
  72. package/dist/unplugin.d.cts.map +1 -1
  73. package/dist/unplugin.d.mts +3 -2
  74. package/dist/unplugin.d.mts.map +1 -1
  75. package/dist/unplugin.mjs +11 -13
  76. package/dist/unplugin.mjs.map +1 -1
  77. package/dist/utils.cjs +0 -14
  78. package/dist/utils.d.mts +1 -1
  79. package/dist/utils.mjs +2 -15
  80. package/dist/vite.cjs +4 -4
  81. package/dist/vite.mjs +1 -1
  82. package/dist/vite.mjs.map +1 -1
  83. package/dist/webpack.cjs +2 -2
  84. package/package.json +64 -53
  85. package/dist/api-CyXUks49.mjs +0 -1078
  86. package/dist/api-CyXUks49.mjs.map +0 -1
  87. package/dist/api-DITWluqG.cjs +0 -1098
  88. package/dist/api-context-BDFU_IC7.cjs +0 -3066
  89. package/dist/api-context-Cb99qIjE.mjs +0 -2986
  90. package/dist/api-context-Cb99qIjE.mjs.map +0 -1
  91. package/dist/config.mjs.map +0 -1
  92. package/dist/constants.mjs.map +0 -1
  93. package/dist/context/index.cjs +0 -7
  94. package/dist/context/index.d.cts +0 -600
  95. package/dist/context/index.d.cts.map +0 -1
  96. package/dist/context/index.d.mts +0 -600
  97. package/dist/context/index.d.mts.map +0 -1
  98. package/dist/context/index.mjs +0 -3
  99. package/dist/plugin-utils.mjs.map +0 -1
  100. package/dist/storage/index.cjs +0 -9
  101. package/dist/storage/index.d.cts +0 -419
  102. package/dist/storage/index.d.cts.map +0 -1
  103. package/dist/storage/index.d.mts +0 -419
  104. package/dist/storage/index.d.mts.map +0 -1
  105. package/dist/storage/index.mjs +0 -3
  106. package/dist/ts-morph-B85ZbV1Q.mjs +0 -102
  107. package/dist/ts-morph-B85ZbV1Q.mjs.map +0 -1
  108. package/dist/ts-morph-BvE8TMhv.cjs +0 -114
  109. package/dist/tsconfig-BjkktvB9.cjs +0 -198
  110. package/dist/tsconfig-DoV1dUYg.mjs +0 -155
  111. package/dist/tsconfig-DoV1dUYg.mjs.map +0 -1
  112. package/dist/types-9O-s0Fpu.d.mts +0 -4
  113. package/dist/types-9O-s0Fpu.d.mts.map +0 -1
  114. package/dist/types-DerAvFjs.d.cts +0 -4
  115. package/dist/types-DerAvFjs.d.cts.map +0 -1
  116. package/dist/typescript/index.cjs +0 -13
  117. package/dist/typescript/index.d.cts +0 -106
  118. package/dist/typescript/index.d.cts.map +0 -1
  119. package/dist/typescript/index.d.mts +0 -106
  120. package/dist/typescript/index.d.mts.map +0 -1
  121. package/dist/typescript/index.mjs +0 -4
  122. package/dist/utils.mjs.map +0 -1
  123. package/dist/virtual-BNy8T32w.cjs +0 -548
  124. package/dist/virtual-PaZGNIrj.mjs +0 -513
  125. package/dist/virtual-PaZGNIrj.mjs.map +0 -1
package/dist/index.d.cts CHANGED
@@ -1,273 +1,26 @@
1
- import { n as __exportAll, r as __reExport, t as types_d_exports } from "./types-DerAvFjs.cjs";
2
- import * as _$_powerlines_core0 from "@powerlines/core";
3
- import { PartialKeys } from "@stryke/types/base";
4
- import * as $ from "@stryke/capnp";
1
+ import { PowerlinesAPI } from "./api.cjs";
2
+ import { types_d_exports } from "./types.cjs";
3
+ import { PowerlinesEngine } from "./engine.cjs";
5
4
  export * from "@powerlines/core";
6
5
 
7
- //#region src/api.d.ts
6
+ //#region src/index.d.ts
7
+ declare namespace index_d_exports {
8
+ export { PowerlinesAPI, PowerlinesEngine, createAPI, createEngine };
9
+ }
8
10
  /**
9
- * The Powerlines API class
11
+ * Creates a new {@link PowerlinesEngine} instance.
10
12
  *
11
- * @remarks
12
- * This class is responsible for managing the Powerlines project lifecycle, including initialization, building, and finalization.
13
- *
14
- * @public
13
+ * @param options - The user configuration options.
14
+ * @returns A promise that resolves to a {@link PowerlinesEngine} instance.
15
15
  */
16
- declare class PowerlinesAPI<TResolvedConfig extends types_d_exports.ResolvedConfig = types_d_exports.ResolvedConfig> implements types_d_exports.API<TResolvedConfig>, AsyncDisposable {
17
- #private;
18
- /**
19
- * The Powerlines context
20
- */
21
- get context(): types_d_exports.APIContext<TResolvedConfig>;
22
- /**
23
- * Create a new Powerlines API instance
24
- *
25
- * @param context - The Powerlines context
26
- */
27
- private constructor();
28
- /**
29
- * Initialize a Powerlines API instance
30
- *
31
- * @param workspaceRoot - The directory of the underlying workspace the Powerlines project exists in
32
- * @param config - An object containing the configuration required to run Powerlines tasks.
33
- * @returns A new instance of the Powerlines API
34
- */
35
- static from<TResolvedConfig extends types_d_exports.ResolvedConfig = types_d_exports.ResolvedConfig>(workspaceRoot: string, config: types_d_exports.InitialUserConfig<TResolvedConfig["userConfig"]>): Promise<PowerlinesAPI<TResolvedConfig>>;
36
- /**
37
- * Generate the Powerlines typescript declaration file
38
- *
39
- * @remarks
40
- * This method will only generate the typescript declaration file for the Powerlines project. It is generally recommended to run the full `prepare` command, which will run this method as part of its process.
41
- *
42
- * @param inlineConfig - The inline configuration for the types command
43
- */
44
- types(inlineConfig?: PartialKeys<types_d_exports.TypesInlineConfig, "command">): Promise<void>;
45
- /**
46
- * Prepare the Powerlines API
47
- *
48
- * @remarks
49
- * This method will prepare the Powerlines API for use, initializing any necessary resources.
50
- *
51
- * @param inlineConfig - The inline configuration for the prepare command
52
- */
53
- prepare(inlineConfig?: PartialKeys<types_d_exports.PrepareInlineConfig, "command"> | PartialKeys<types_d_exports.TypesInlineConfig, "command"> | PartialKeys<types_d_exports.NewInlineConfig, "command"> | PartialKeys<types_d_exports.CleanInlineConfig, "command"> | PartialKeys<types_d_exports.BuildInlineConfig, "command"> | PartialKeys<types_d_exports.LintInlineConfig, "command"> | PartialKeys<types_d_exports.DocsInlineConfig, "command"> | PartialKeys<types_d_exports.DeployInlineConfig, "command">): Promise<void>;
54
- /**
55
- * Create a new Powerlines project
56
- *
57
- * @remarks
58
- * This method will create a new Powerlines project in the current directory.
59
- *
60
- * @param inlineConfig - The inline configuration for the new command
61
- * @returns A promise that resolves when the project has been created
62
- */
63
- new(inlineConfig: PartialKeys<types_d_exports.NewInlineConfig, "command">): Promise<void>;
64
- /**
65
- * Clean any previously prepared artifacts
66
- *
67
- * @remarks
68
- * This method will remove the previous Powerlines artifacts from the project.
69
- *
70
- * @param inlineConfig - The inline configuration for the clean command
71
- * @returns A promise that resolves when the clean command has completed
72
- */
73
- clean(inlineConfig?: PartialKeys<types_d_exports.CleanInlineConfig, "command"> | PartialKeys<types_d_exports.PrepareInlineConfig, "command">): Promise<void>;
74
- /**
75
- * Lint the project
76
- *
77
- * @param inlineConfig - The inline configuration for the lint command
78
- * @returns A promise that resolves when the lint command has completed
79
- */
80
- lint(inlineConfig?: PartialKeys<types_d_exports.LintInlineConfig, "command"> | PartialKeys<types_d_exports.BuildInlineConfig, "command">): Promise<void>;
81
- /**
82
- * Build the project
83
- *
84
- * @remarks
85
- * This method will build the Powerlines project, generating the necessary artifacts.
86
- *
87
- * @param inlineConfig - The inline configuration for the build command
88
- * @returns A promise that resolves when the build command has completed
89
- */
90
- build(inlineConfig?: PartialKeys<types_d_exports.BuildInlineConfig, "command">): Promise<void>;
91
- /**
92
- * Prepare the documentation for the project
93
- *
94
- * @param inlineConfig - The inline configuration for the docs command
95
- * @returns A promise that resolves when the documentation generation has completed
96
- */
97
- docs(inlineConfig?: types_d_exports.DocsInlineConfig): Promise<void>;
98
- /**
99
- * Deploy the project source code
100
- *
101
- * @remarks
102
- * This method will prepare and build the Powerlines project, generating the necessary artifacts for the deployment.
103
- *
104
- * @param inlineConfig - The inline configuration for the deploy command
105
- */
106
- deploy(inlineConfig?: PartialKeys<types_d_exports.DeployInlineConfig, "command">): Promise<void>;
107
- /**
108
- * Finalization/cleanup processing for the Powerlines API
109
- *
110
- * @remarks
111
- * This step includes any final processes or clean up required by Powerlines. It will be run after each Powerlines command.
112
- *
113
- * @returns A promise that resolves when the finalization process has completed
114
- */
115
- finalize(): Promise<void>;
116
- /**
117
- * Invokes the configured plugin hooks
118
- *
119
- * @remarks
120
- * By default, it will call the `"pre"`, `"normal"`, and `"post"` ordered hooks in sequence
121
- *
122
- * @param hook - The hook to call
123
- * @param options - The options to provide to the hook
124
- * @param args - The arguments to pass to the hook
125
- * @returns The result of the hook call
126
- */
127
- callHook<TKey extends string>(hook: TKey, options: types_d_exports.CallHookOptions & {
128
- environment?: string | types_d_exports.EnvironmentContext<TResolvedConfig>;
129
- }, ...args: types_d_exports.InferHookParameters<types_d_exports.PluginContext<TResolvedConfig>, TKey>): Promise<ReturnType<_$_powerlines_core0.InferHookFunction<types_d_exports.PluginContext<TResolvedConfig>, TKey>> | undefined>;
130
- /**
131
- * Dispose of the Powerlines API instance
132
- *
133
- * @remarks
134
- * This method will finalize the Powerlines API instance, cleaning up any resources used.
135
- */
136
- [Symbol.asyncDispose](): Promise<void>;
137
- }
138
- //#endregion
139
- //#region schemas/fs.d.ts
140
- declare const _capnpFileId: bigint;
141
- declare class FileMetadata_KeyValuePair extends $.Struct {
142
- static readonly _capnp: {
143
- displayName: string;
144
- id: string;
145
- size: $.ObjectSize;
146
- };
147
- get key(): string;
148
- set key(value: string);
149
- get value(): string;
150
- set value(value: string);
151
- toString(): string;
152
- }
153
- /**
154
- * The identifier for the file data.
155
- *
156
- */
157
- declare class FileMetadata extends $.Struct {
158
- static readonly KeyValuePair: typeof FileMetadata_KeyValuePair;
159
- static readonly _capnp: {
160
- displayName: string;
161
- id: string;
162
- size: $.ObjectSize;
163
- defaultType: string;
164
- };
165
- static _Properties: $.ListCtor<FileMetadata_KeyValuePair>;
166
- /**
167
- * The type of the file.
168
- *
169
- */
170
- get id(): string;
171
- set id(value: string);
172
- /**
173
- * The timestamp representing the file's creation date.
174
- *
175
- */
176
- get type(): string;
177
- set type(value: string);
178
- /**
179
- * Additional metadata associated with the file.
180
- *
181
- */
182
- get timestamp(): number;
183
- set timestamp(value: number);
184
- _adoptProperties(value: $.Orphan<$.List<FileMetadata_KeyValuePair>>): void;
185
- _disownProperties(): $.Orphan<$.List<FileMetadata_KeyValuePair>>;
186
- get properties(): $.List<FileMetadata_KeyValuePair>;
187
- _hasProperties(): boolean;
188
- _initProperties(length: number): $.List<FileMetadata_KeyValuePair>;
189
- set properties(value: $.List<FileMetadata_KeyValuePair>);
190
- toString(): string;
191
- }
192
- /**
193
- * An identifier for the file.
194
- *
195
- */
196
- declare class FileId extends $.Struct {
197
- static readonly _capnp: {
198
- displayName: string;
199
- id: string;
200
- size: $.ObjectSize;
201
- };
202
- /**
203
- * A virtual (or actual) path to the file in the file system.
204
- *
205
- */
206
- get id(): string;
207
- set id(value: string);
208
- get path(): string;
209
- set path(value: string);
210
- toString(): string;
211
- }
212
- /**
213
- * An identifier for the file.
214
- *
215
- */
216
- declare class FileStorage extends $.Struct {
217
- static readonly _capnp: {
218
- displayName: string;
219
- id: string;
220
- size: $.ObjectSize;
221
- };
222
- /**
223
- * A virtual (or actual) path to the file in the file system.
224
- *
225
- */
226
- get path(): string;
227
- set path(value: string);
228
- get code(): string;
229
- set code(value: string);
230
- toString(): string;
231
- }
232
- declare class FileSystem extends $.Struct {
233
- static readonly _capnp: {
234
- displayName: string;
235
- id: string;
236
- size: $.ObjectSize;
237
- };
238
- static _Ids: $.ListCtor<FileId>;
239
- static _Storage: $.ListCtor<FileStorage>;
240
- static _Metadata: $.ListCtor<FileMetadata>;
241
- _adoptIds(value: $.Orphan<$.List<FileId>>): void;
242
- _disownIds(): $.Orphan<$.List<FileId>>;
243
- get ids(): $.List<FileId>;
244
- _hasIds(): boolean;
245
- _initIds(length: number): $.List<FileId>;
246
- set ids(value: $.List<FileId>);
247
- _adoptStorage(value: $.Orphan<$.List<FileStorage>>): void;
248
- _disownStorage(): $.Orphan<$.List<FileStorage>>;
249
- get storage(): $.List<FileStorage>;
250
- _hasStorage(): boolean;
251
- _initStorage(length: number): $.List<FileStorage>;
252
- set storage(value: $.List<FileStorage>);
253
- _adoptMetadata(value: $.Orphan<$.List<FileMetadata>>): void;
254
- _disownMetadata(): $.Orphan<$.List<FileMetadata>>;
255
- get metadata(): $.List<FileMetadata>;
256
- _hasMetadata(): boolean;
257
- _initMetadata(length: number): $.List<FileMetadata>;
258
- set metadata(value: $.List<FileMetadata>);
259
- toString(): string;
260
- }
261
- declare namespace index_d_exports {
262
- export { FileId, FileMetadata, FileMetadata_KeyValuePair, FileStorage, FileSystem, PowerlinesAPI, _capnpFileId, createPowerlines };
263
- }
16
+ declare function createEngine(options: types_d_exports.EngineOptions): Promise<PowerlinesEngine>;
264
17
  /**
265
18
  * Creates a new {@link PowerlinesAPI} instance.
266
19
  *
267
20
  * @param options - The user configuration options.
268
21
  * @returns A promise that resolves to a {@link PowerlinesAPI} instance.
269
22
  */
270
- declare function createPowerlines(options?: Partial<types_d_exports.UserConfig>): Promise<PowerlinesAPI>;
23
+ declare function createAPI(options: types_d_exports.EngineOptions): Promise<PowerlinesAPI>;
271
24
  //#endregion
272
- export { FileId, FileMetadata, FileMetadata_KeyValuePair, FileStorage, FileSystem, PowerlinesAPI, _capnpFileId, createPowerlines };
25
+ export { PowerlinesAPI, PowerlinesEngine, createAPI, createEngine };
273
26
  //# sourceMappingURL=index.d.cts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.cts","names":[],"sources":["../src/api.ts","../schemas/fs.ts","../src/index.ts"],"mappings":";;;;;;;;;;;;;AA8GA;;cAAa,aAAA,yBACa,eAAA,CAAA,cAAA,GAAiB,eAAA,CAAA,cAAA,aAE9B,eAAA,CAAA,GAAA,CAAI,eAAA,GAAkB,eAAA;EAAA;EAFQ;;;EAAA,IAY9B,OAAA,CAAA,GAAW,eAAA,CAAA,UAAA,CAAW,eAAA;EAqBP;;;;;EAAA,QAZnB,WAAA,CAAA;EAgBJ;;;;;;;EAAA,OALiB,IAAA,yBACM,eAAA,CAAA,cAAA,GAAiB,eAAA,CAAA,cAAA,CAAA,CAEzC,aAAA,UACA,MAAA,EAAQ,eAAA,CAAA,iBAAA,CAAkB,eAAA,kBACzB,OAAA,CAAQ,aAAA,CAAc,eAAA;EA+MP;;;;;;;;EAtJL,KAAA,CACX,YAAA,GAAc,WAAA,CAAY,eAAA,CAAA,iBAAA,eAEzB,OAAA;EAuJG;;;;;;;;EARO,OAAA,CACX,YAAA,GACI,WAAA,CAAY,eAAA,CAAA,mBAAA,eACZ,WAAA,CAAY,eAAA,CAAA,iBAAA,eACZ,WAAA,CAAY,eAAA,CAAA,eAAA,eACZ,WAAA,CAAY,eAAA,CAAA,iBAAA,eACZ,WAAA,CAAY,eAAA,CAAA,iBAAA,eACZ,WAAA,CAAY,eAAA,CAAA,gBAAA,eACZ,WAAA,CAAY,eAAA,CAAA,gBAAA,eACZ,WAAA,CAAY,eAAA,CAAA,kBAAA,eAAuD,OAAA;EA0NvD;;;;;;;;;EAvFL,GAAA,CAAI,YAAA,EAAc,WAAA,CAAY,eAAA,CAAA,eAAA,eAA2B,OAAA;EAuKnE;;;;;;;;;EAnFU,KAAA,CACX,YAAA,GACI,WAAA,CAAY,eAAA,CAAA,iBAAA,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AAE,IAAA,CAAK,YAAA;EAGX,QAAA,CAAA;AAAA;AAAA;;;;;;;ADlGlB;;iBEtEsB,gBAAA,CACpB,OAAA,GAAS,OAAA,CAAQ,eAAA,CAAA,UAAA,IAChB,OAAA,CAAQ,aAAA"}
1
+ {"version":3,"file":"index.d.cts","names":[],"sources":["../src/index.ts"],"mappings":";;;;;;;;;;;;AAuCA;;;iBAAsB,YAAA,CACpB,OAAA,EAAS,eAAA,CAAA,aAAA,GACR,OAAA,CAAQ,gBAAA;;;;;;;iBAUW,SAAA,CACpB,OAAA,EAAS,eAAA,CAAA,aAAA,GACR,OAAA,CAAQ,aAAA"}
package/dist/index.d.mts CHANGED
@@ -1,273 +1,26 @@
1
- import { t as types_d_exports } from "./types-9O-s0Fpu.mjs";
2
- import * as $ from "@stryke/capnp";
3
- import * as _$_powerlines_core0 from "@powerlines/core";
4
- import { PartialKeys } from "@stryke/types/base";
1
+ import { PowerlinesAPI } from "./api.mjs";
2
+ import { types_d_exports } from "./types.mjs";
3
+ import { PowerlinesEngine } from "./engine.mjs";
5
4
  export * from "@powerlines/core";
6
5
 
7
- //#region src/api.d.ts
6
+ //#region src/index.d.ts
7
+ declare namespace index_d_exports {
8
+ export { PowerlinesAPI, PowerlinesEngine, createAPI, createEngine };
9
+ }
8
10
  /**
9
- * The Powerlines API class
11
+ * Creates a new {@link PowerlinesEngine} instance.
10
12
  *
11
- * @remarks
12
- * This class is responsible for managing the Powerlines project lifecycle, including initialization, building, and finalization.
13
- *
14
- * @public
13
+ * @param options - The user configuration options.
14
+ * @returns A promise that resolves to a {@link PowerlinesEngine} instance.
15
15
  */
16
- declare class PowerlinesAPI<TResolvedConfig extends types_d_exports.ResolvedConfig = types_d_exports.ResolvedConfig> implements types_d_exports.API<TResolvedConfig>, AsyncDisposable {
17
- #private;
18
- /**
19
- * The Powerlines context
20
- */
21
- get context(): types_d_exports.APIContext<TResolvedConfig>;
22
- /**
23
- * Create a new Powerlines API instance
24
- *
25
- * @param context - The Powerlines context
26
- */
27
- private constructor();
28
- /**
29
- * Initialize a Powerlines API instance
30
- *
31
- * @param workspaceRoot - The directory of the underlying workspace the Powerlines project exists in
32
- * @param config - An object containing the configuration required to run Powerlines tasks.
33
- * @returns A new instance of the Powerlines API
34
- */
35
- static from<TResolvedConfig extends types_d_exports.ResolvedConfig = types_d_exports.ResolvedConfig>(workspaceRoot: string, config: types_d_exports.InitialUserConfig<TResolvedConfig["userConfig"]>): Promise<PowerlinesAPI<TResolvedConfig>>;
36
- /**
37
- * Generate the Powerlines typescript declaration file
38
- *
39
- * @remarks
40
- * This method will only generate the typescript declaration file for the Powerlines project. It is generally recommended to run the full `prepare` command, which will run this method as part of its process.
41
- *
42
- * @param inlineConfig - The inline configuration for the types command
43
- */
44
- types(inlineConfig?: PartialKeys<types_d_exports.TypesInlineConfig, "command">): Promise<void>;
45
- /**
46
- * Prepare the Powerlines API
47
- *
48
- * @remarks
49
- * This method will prepare the Powerlines API for use, initializing any necessary resources.
50
- *
51
- * @param inlineConfig - The inline configuration for the prepare command
52
- */
53
- prepare(inlineConfig?: PartialKeys<types_d_exports.PrepareInlineConfig, "command"> | PartialKeys<types_d_exports.TypesInlineConfig, "command"> | PartialKeys<types_d_exports.NewInlineConfig, "command"> | PartialKeys<types_d_exports.CleanInlineConfig, "command"> | PartialKeys<types_d_exports.BuildInlineConfig, "command"> | PartialKeys<types_d_exports.LintInlineConfig, "command"> | PartialKeys<types_d_exports.DocsInlineConfig, "command"> | PartialKeys<types_d_exports.DeployInlineConfig, "command">): Promise<void>;
54
- /**
55
- * Create a new Powerlines project
56
- *
57
- * @remarks
58
- * This method will create a new Powerlines project in the current directory.
59
- *
60
- * @param inlineConfig - The inline configuration for the new command
61
- * @returns A promise that resolves when the project has been created
62
- */
63
- new(inlineConfig: PartialKeys<types_d_exports.NewInlineConfig, "command">): Promise<void>;
64
- /**
65
- * Clean any previously prepared artifacts
66
- *
67
- * @remarks
68
- * This method will remove the previous Powerlines artifacts from the project.
69
- *
70
- * @param inlineConfig - The inline configuration for the clean command
71
- * @returns A promise that resolves when the clean command has completed
72
- */
73
- clean(inlineConfig?: PartialKeys<types_d_exports.CleanInlineConfig, "command"> | PartialKeys<types_d_exports.PrepareInlineConfig, "command">): Promise<void>;
74
- /**
75
- * Lint the project
76
- *
77
- * @param inlineConfig - The inline configuration for the lint command
78
- * @returns A promise that resolves when the lint command has completed
79
- */
80
- lint(inlineConfig?: PartialKeys<types_d_exports.LintInlineConfig, "command"> | PartialKeys<types_d_exports.BuildInlineConfig, "command">): Promise<void>;
81
- /**
82
- * Build the project
83
- *
84
- * @remarks
85
- * This method will build the Powerlines project, generating the necessary artifacts.
86
- *
87
- * @param inlineConfig - The inline configuration for the build command
88
- * @returns A promise that resolves when the build command has completed
89
- */
90
- build(inlineConfig?: PartialKeys<types_d_exports.BuildInlineConfig, "command">): Promise<void>;
91
- /**
92
- * Prepare the documentation for the project
93
- *
94
- * @param inlineConfig - The inline configuration for the docs command
95
- * @returns A promise that resolves when the documentation generation has completed
96
- */
97
- docs(inlineConfig?: types_d_exports.DocsInlineConfig): Promise<void>;
98
- /**
99
- * Deploy the project source code
100
- *
101
- * @remarks
102
- * This method will prepare and build the Powerlines project, generating the necessary artifacts for the deployment.
103
- *
104
- * @param inlineConfig - The inline configuration for the deploy command
105
- */
106
- deploy(inlineConfig?: PartialKeys<types_d_exports.DeployInlineConfig, "command">): Promise<void>;
107
- /**
108
- * Finalization/cleanup processing for the Powerlines API
109
- *
110
- * @remarks
111
- * This step includes any final processes or clean up required by Powerlines. It will be run after each Powerlines command.
112
- *
113
- * @returns A promise that resolves when the finalization process has completed
114
- */
115
- finalize(): Promise<void>;
116
- /**
117
- * Invokes the configured plugin hooks
118
- *
119
- * @remarks
120
- * By default, it will call the `"pre"`, `"normal"`, and `"post"` ordered hooks in sequence
121
- *
122
- * @param hook - The hook to call
123
- * @param options - The options to provide to the hook
124
- * @param args - The arguments to pass to the hook
125
- * @returns The result of the hook call
126
- */
127
- callHook<TKey extends string>(hook: TKey, options: types_d_exports.CallHookOptions & {
128
- environment?: string | types_d_exports.EnvironmentContext<TResolvedConfig>;
129
- }, ...args: types_d_exports.InferHookParameters<types_d_exports.PluginContext<TResolvedConfig>, TKey>): Promise<ReturnType<_$_powerlines_core0.InferHookFunction<types_d_exports.PluginContext<TResolvedConfig>, TKey>> | undefined>;
130
- /**
131
- * Dispose of the Powerlines API instance
132
- *
133
- * @remarks
134
- * This method will finalize the Powerlines API instance, cleaning up any resources used.
135
- */
136
- [Symbol.asyncDispose](): Promise<void>;
137
- }
138
- //#endregion
139
- //#region schemas/fs.d.ts
140
- declare const _capnpFileId: bigint;
141
- declare class FileMetadata_KeyValuePair extends $.Struct {
142
- static readonly _capnp: {
143
- displayName: string;
144
- id: string;
145
- size: $.ObjectSize;
146
- };
147
- get key(): string;
148
- set key(value: string);
149
- get value(): string;
150
- set value(value: string);
151
- toString(): string;
152
- }
153
- /**
154
- * The identifier for the file data.
155
- *
156
- */
157
- declare class FileMetadata extends $.Struct {
158
- static readonly KeyValuePair: typeof FileMetadata_KeyValuePair;
159
- static readonly _capnp: {
160
- displayName: string;
161
- id: string;
162
- size: $.ObjectSize;
163
- defaultType: string;
164
- };
165
- static _Properties: $.ListCtor<FileMetadata_KeyValuePair>;
166
- /**
167
- * The type of the file.
168
- *
169
- */
170
- get id(): string;
171
- set id(value: string);
172
- /**
173
- * The timestamp representing the file's creation date.
174
- *
175
- */
176
- get type(): string;
177
- set type(value: string);
178
- /**
179
- * Additional metadata associated with the file.
180
- *
181
- */
182
- get timestamp(): number;
183
- set timestamp(value: number);
184
- _adoptProperties(value: $.Orphan<$.List<FileMetadata_KeyValuePair>>): void;
185
- _disownProperties(): $.Orphan<$.List<FileMetadata_KeyValuePair>>;
186
- get properties(): $.List<FileMetadata_KeyValuePair>;
187
- _hasProperties(): boolean;
188
- _initProperties(length: number): $.List<FileMetadata_KeyValuePair>;
189
- set properties(value: $.List<FileMetadata_KeyValuePair>);
190
- toString(): string;
191
- }
192
- /**
193
- * An identifier for the file.
194
- *
195
- */
196
- declare class FileId extends $.Struct {
197
- static readonly _capnp: {
198
- displayName: string;
199
- id: string;
200
- size: $.ObjectSize;
201
- };
202
- /**
203
- * A virtual (or actual) path to the file in the file system.
204
- *
205
- */
206
- get id(): string;
207
- set id(value: string);
208
- get path(): string;
209
- set path(value: string);
210
- toString(): string;
211
- }
212
- /**
213
- * An identifier for the file.
214
- *
215
- */
216
- declare class FileStorage extends $.Struct {
217
- static readonly _capnp: {
218
- displayName: string;
219
- id: string;
220
- size: $.ObjectSize;
221
- };
222
- /**
223
- * A virtual (or actual) path to the file in the file system.
224
- *
225
- */
226
- get path(): string;
227
- set path(value: string);
228
- get code(): string;
229
- set code(value: string);
230
- toString(): string;
231
- }
232
- declare class FileSystem extends $.Struct {
233
- static readonly _capnp: {
234
- displayName: string;
235
- id: string;
236
- size: $.ObjectSize;
237
- };
238
- static _Ids: $.ListCtor<FileId>;
239
- static _Storage: $.ListCtor<FileStorage>;
240
- static _Metadata: $.ListCtor<FileMetadata>;
241
- _adoptIds(value: $.Orphan<$.List<FileId>>): void;
242
- _disownIds(): $.Orphan<$.List<FileId>>;
243
- get ids(): $.List<FileId>;
244
- _hasIds(): boolean;
245
- _initIds(length: number): $.List<FileId>;
246
- set ids(value: $.List<FileId>);
247
- _adoptStorage(value: $.Orphan<$.List<FileStorage>>): void;
248
- _disownStorage(): $.Orphan<$.List<FileStorage>>;
249
- get storage(): $.List<FileStorage>;
250
- _hasStorage(): boolean;
251
- _initStorage(length: number): $.List<FileStorage>;
252
- set storage(value: $.List<FileStorage>);
253
- _adoptMetadata(value: $.Orphan<$.List<FileMetadata>>): void;
254
- _disownMetadata(): $.Orphan<$.List<FileMetadata>>;
255
- get metadata(): $.List<FileMetadata>;
256
- _hasMetadata(): boolean;
257
- _initMetadata(length: number): $.List<FileMetadata>;
258
- set metadata(value: $.List<FileMetadata>);
259
- toString(): string;
260
- }
261
- declare namespace index_d_exports {
262
- export { FileId, FileMetadata, FileMetadata_KeyValuePair, FileStorage, FileSystem, PowerlinesAPI, _capnpFileId, createPowerlines };
263
- }
16
+ declare function createEngine(options: types_d_exports.EngineOptions): Promise<PowerlinesEngine>;
264
17
  /**
265
18
  * Creates a new {@link PowerlinesAPI} instance.
266
19
  *
267
20
  * @param options - The user configuration options.
268
21
  * @returns A promise that resolves to a {@link PowerlinesAPI} instance.
269
22
  */
270
- declare function createPowerlines(options?: Partial<types_d_exports.UserConfig>): Promise<PowerlinesAPI>;
23
+ declare function createAPI(options: types_d_exports.EngineOptions): Promise<PowerlinesAPI>;
271
24
  //#endregion
272
- export { FileId, FileMetadata, FileMetadata_KeyValuePair, FileStorage, FileSystem, PowerlinesAPI, _capnpFileId, createPowerlines };
25
+ export { PowerlinesAPI, PowerlinesEngine, createAPI, createEngine };
273
26
  //# sourceMappingURL=index.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.mts","names":[],"sources":["../src/api.ts","../schemas/fs.ts","../src/index.ts"],"mappings":";;;;;;;;;;;;;;AA8GA;cAAa,aAAA,yBACa,eAAA,CAAA,cAAA,GAAiB,eAAA,CAAA,cAAA,aAE9B,eAAA,CAAA,GAAA,CAAI,eAAA,GAAkB,eAAA;EAAA;EAFT;;;EAAA,IAYb,OAAA,CAAA,GAAW,eAAA,CAAA,UAAA,CAAW,eAAA;EAAX;;;;;EAAA,QASf,WAAA,CAAA;EAgBI;;;;;;;EAAA,OALS,IAAA,yBACM,eAAA,CAAA,cAAA,GAAiB,eAAA,CAAA,cAAA,CAAA,CAEzC,aAAA,UACA,MAAA,EAAQ,eAAA,CAAA,iBAAA,CAAkB,eAAA,kBACzB,OAAA,CAAQ,aAAA,CAAc,eAAA;EA8MnB;;;;;;;;EArJO,KAAA,CACX,YAAA,GAAc,WAAA,CAAY,eAAA,CAAA,iBAAA,eAEzB,OAAA;EAuJe;;;;;;;;EARL,OAAA,CACX,YAAA,GACI,WAAA,CAAY,eAAA,CAAA,mBAAA,eACZ,WAA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AK,WAAA;EAAA,IAGjC,OAAA,CAAQ,KAAA,EAAO,CAAA,CAAE,IAAA,CAAK,WAAA;EAG1B,cAAA,CAAe,KAAA,EAAO,CAAA,CAAE,MAAA,CAAO,CAAA,CAAE,IAAA,CAAK,YAAA;EAGtC,eAAA,CAAA,GAAmB,CAAA,CAAE,MAAA,CAAO,CAAA,CAAE,IAAA,CAAK,YAAA;EAAA,IAG/B,QAAA,CAAA,GAAY,CAAA,CAAE,IAAA,CAAK,YAAA;EAGvB,YAAA,CAAA;EAGA,aAAA,CAAc,MAAA,WAAiB,CAAA,CAAE,IAAA,CAAK,YAAA;EAAA,IAGlC,QAAA,CAAS,KAAA,EAAO,CAAA,CAAE,IAAA,CAAK,YAAA;EAGX,QAAA,CAAA;AAAA;AAAA;;;;;;;;ADlGlB;iBEtEsB,gBAAA,CACpB,OAAA,GAAS,OAAA,CAAQ,eAAA,CAAA,UAAA,IAChB,OAAA,CAAQ,aAAA"}
1
+ {"version":3,"file":"index.d.mts","names":[],"sources":["../src/index.ts"],"mappings":";;;;;;;;;;;;AAuCA;;;iBAAsB,YAAA,CACpB,OAAA,EAAS,eAAA,CAAA,aAAA,GACR,OAAA,CAAQ,gBAAA;;;;;;;iBAUW,SAAA,CACpB,OAAA,EAAS,eAAA,CAAA,aAAA,GACR,OAAA,CAAQ,aAAA"}
package/dist/index.mjs CHANGED
@@ -1,6 +1,5 @@
1
- import { t as PowerlinesAPI } from "./api-CyXUks49.mjs";
2
- import { a as FileId, c as FileStorage, l as FileSystem, o as FileMetadata, s as FileMetadata_KeyValuePair, u as _capnpFileId } from "./api-context-Cb99qIjE.mjs";
3
- import { getWorkspaceRoot } from "@stryke/fs/get-workspace-root";
1
+ import { PowerlinesAPI } from "./api.mjs";
2
+ import { PowerlinesEngine } from "./engine.mjs";
4
3
 
5
4
  //#region src/index.ts
6
5
  /**
@@ -12,17 +11,24 @@ import { getWorkspaceRoot } from "@stryke/fs/get-workspace-root";
12
11
  * @packageDocumentation
13
12
  */
14
13
  /**
14
+ * Creates a new {@link PowerlinesEngine} instance.
15
+ *
16
+ * @param options - The user configuration options.
17
+ * @returns A promise that resolves to a {@link PowerlinesEngine} instance.
18
+ */
19
+ async function createEngine(options) {
20
+ return PowerlinesEngine.fromOptions(options);
21
+ }
22
+ /**
15
23
  * Creates a new {@link PowerlinesAPI} instance.
16
24
  *
17
25
  * @param options - The user configuration options.
18
26
  * @returns A promise that resolves to a {@link PowerlinesAPI} instance.
19
27
  */
20
- async function createPowerlines(options = {}) {
21
- options.root ??= process.cwd();
22
- const workspaceRoot = getWorkspaceRoot(options.root);
23
- return PowerlinesAPI.from(workspaceRoot, options);
28
+ async function createAPI(options) {
29
+ return PowerlinesAPI.fromOptions(options);
24
30
  }
25
31
 
26
32
  //#endregion
27
- export { FileId, FileMetadata, FileMetadata_KeyValuePair, FileStorage, FileSystem, PowerlinesAPI, _capnpFileId, createPowerlines };
33
+ export { PowerlinesAPI, PowerlinesEngine, createAPI, createEngine };
28
34
  //# sourceMappingURL=index.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.mjs","names":[],"sources":["../src/index.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\n/**\n * The powerlines library used by Storm Software for building NodeJS applications.\n *\n * @remarks\n * A build toolkit and runtime used by Storm Software in TypeScript applications\n *\n * @packageDocumentation\n */\n\nimport { getWorkspaceRoot } from \"@stryke/fs/get-workspace-root\";\nimport { PowerlinesAPI } from \"./api\";\nimport { UserConfig } from \"./types\";\n\nexport * from \"../schemas/fs\";\nexport type * from \"./types\";\n\n/**\n * Creates a new {@link PowerlinesAPI} instance.\n *\n * @param options - The user configuration options.\n * @returns A promise that resolves to a {@link PowerlinesAPI} instance.\n */\nexport async function createPowerlines(\n options: Partial<UserConfig> = {}\n): Promise<PowerlinesAPI> {\n options.root ??= process.cwd();\n const workspaceRoot = getWorkspaceRoot(options.root);\n\n return PowerlinesAPI.from(\n workspaceRoot,\n options as Parameters<typeof PowerlinesAPI.from>[1]\n );\n}\n\nexport { PowerlinesAPI };\n"],"mappings":";;;;;;;;;;;;;;;;;;;AAwCA,eAAsB,iBACpB,UAA+B,EAAE,EACT;AACxB,SAAQ,SAAS,QAAQ,KAAK;CAC9B,MAAM,gBAAgB,iBAAiB,QAAQ,KAAK;AAEpD,QAAO,cAAc,KACnB,eACA,QACD"}
1
+ {"version":3,"file":"index.mjs","names":[],"sources":["../src/index.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\n/**\n * The powerlines library used by Storm Software for building NodeJS applications.\n *\n * @remarks\n * A build toolkit and runtime used by Storm Software in TypeScript applications\n *\n * @packageDocumentation\n */\n\nimport { PowerlinesAPI } from \"./api\";\nimport { PowerlinesEngine } from \"./engine\";\nimport type { EngineOptions } from \"./types\";\n\nexport type * from \"./types\";\n\n/**\n * Creates a new {@link PowerlinesEngine} instance.\n *\n * @param options - The user configuration options.\n * @returns A promise that resolves to a {@link PowerlinesEngine} instance.\n */\nexport async function createEngine(\n options: EngineOptions\n): Promise<PowerlinesEngine> {\n return PowerlinesEngine.fromOptions(options);\n}\n\n/**\n * Creates a new {@link PowerlinesAPI} instance.\n *\n * @param options - The user configuration options.\n * @returns A promise that resolves to a {@link PowerlinesAPI} instance.\n */\nexport async function createAPI(\n options: EngineOptions\n): Promise<PowerlinesAPI> {\n return PowerlinesAPI.fromOptions(options);\n}\n\nexport { PowerlinesAPI, PowerlinesEngine };\n"],"mappings":";;;;;;;;;;;;;;;;;;AAuCA,eAAsB,aACpB,SAC2B;AAC3B,QAAO,iBAAiB,YAAY,QAAQ;;;;;;;;AAS9C,eAAsB,UACpB,SACwB;AACxB,QAAO,cAAc,YAAY,QAAQ"}
package/dist/nuxt.cjs CHANGED
@@ -1,7 +1,7 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
2
- const require_chunk = require('./chunk-AIJqnxB6.cjs');
3
- const require_api = require('./api-DITWluqG.cjs');
2
+ const require_runtime = require('./_virtual/_rolldown/runtime.cjs');
4
3
  const require_vite = require('./vite.cjs');
4
+ const require_package = require('./package.cjs');
5
5
  const require_webpack = require('./webpack.cjs');
6
6
  let _nuxt_kit = require("@nuxt/kit");
7
7
 
@@ -29,8 +29,8 @@ let _nuxt_kit = require("@nuxt/kit");
29
29
  */
30
30
  const unplugin = (0, _nuxt_kit.defineNuxtModule)({
31
31
  meta: {
32
- name: require_api.name,
33
- version: require_api.version,
32
+ name: require_package.name,
33
+ version: require_package.version,
34
34
  configKey: "powerlines",
35
35
  compatibility: { builder: { vite: "^6.0.0" } }
36
36
  },