@pikku/cli 0.10.1 → 0.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.pikku/channel/pikku-channel-types.gen.ts +4 -3
- package/.pikku/channel/pikku-channels-map.gen.d.ts +5 -2
- package/.pikku/channel/pikku-channels-meta.gen.ts +1 -1
- package/.pikku/channel/pikku-channels.gen.ts +1 -1
- package/.pikku/cli/pikku-cli-types.gen.ts +23 -1
- package/.pikku/cli/pikku-cli-wirings-meta.gen.ts +8 -116
- package/.pikku/cli/pikku-cli-wirings.gen.ts +2 -3
- package/.pikku/function/pikku-function-types.gen.ts +1 -1
- package/.pikku/function/pikku-functions-meta.gen.ts +265 -138
- package/.pikku/function/pikku-functions-meta.min.gen.ts +62 -32
- package/.pikku/function/pikku-functions.gen.ts +9 -1
- package/.pikku/http/pikku-http-types.gen.ts +1 -1
- package/.pikku/http/pikku-http-wirings-map.gen.d.ts +5 -2
- package/.pikku/http/pikku-http-wirings-meta.gen.ts +1 -1
- package/.pikku/http/pikku-http-wirings.gen.ts +1 -1
- package/.pikku/mcp/pikku-mcp-types.gen.ts +1 -1
- package/.pikku/mcp/pikku-mcp-wirings-meta.gen.ts +1 -1
- package/.pikku/mcp/pikku-mcp-wirings.gen.ts +1 -1
- package/.pikku/pikku-bootstrap.gen.ts +4 -1
- package/.pikku/pikku-services.gen.ts +21 -12
- package/.pikku/pikku-types.gen.ts +1 -1
- package/.pikku/pikku-websocket.gen.ts +15 -1
- package/.pikku/queue/pikku-queue-types.gen.ts +1 -1
- package/.pikku/queue/pikku-queue-workers-wirings-map.gen.d.ts +5 -2
- package/.pikku/queue/pikku-queue-workers-wirings-meta.gen.ts +7 -2
- package/.pikku/queue/pikku-queue-workers-wirings.gen.ts +1 -1
- package/.pikku/rpc/pikku-remote-rpc-workers.gen.ts +27 -0
- package/.pikku/rpc/pikku-rpc-wirings-map.gen.d.ts +13 -3
- package/.pikku/rpc/pikku-rpc-wirings-map.internal.gen.d.ts +26 -10
- package/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.ts +15 -9
- package/.pikku/scheduler/pikku-scheduler-types.gen.ts +1 -1
- package/.pikku/scheduler/pikku-schedulers-wirings-meta.gen.ts +1 -1
- package/.pikku/scheduler/pikku-schedulers-wirings.gen.ts +1 -1
- package/.pikku/schemas/register.gen.ts +17 -5
- package/.pikku/schemas/schemas/PikkuCLIConfig.schema.json +1 -1
- package/.pikku/schemas/schemas/PikkuChannelsOutput.schema.json +1 -1
- package/.pikku/schemas/schemas/PikkuPublicRPCOutput.schema.json +1 -0
- package/.pikku/schemas/schemas/PikkuRemoteRPCOutput.schema.json +1 -0
- package/.pikku/schemas/schemas/PikkuSchemasOutput.schema.json +1 -1
- package/.pikku/schemas/schemas/PikkuWorkflowOutput.schema.json +1 -0
- package/.pikku/workflow/pikku-workflow-map.gen.d.ts +62 -0
- package/.pikku/workflow/pikku-workflow-types.gen.ts +92 -0
- package/.pikku/workflow/pikku-workflow-wirings-meta.gen.ts +5 -0
- package/.pikku/workflow/pikku-workflow-wirings.gen.ts +4 -0
- package/CHANGELOG.md +57 -0
- package/bin/pikku.ts +30 -21
- package/cli.schema.json +1 -1
- package/dist/.pikku/channel/pikku-channel-types.gen.d.ts +4 -3
- package/dist/.pikku/channel/pikku-channel-types.gen.js +1 -1
- package/dist/.pikku/channel/pikku-channels-meta.gen.js +1 -1
- package/dist/.pikku/channel/pikku-channels.gen.d.ts +1 -1
- package/dist/.pikku/channel/pikku-channels.gen.js +1 -1
- package/dist/.pikku/cli/pikku-cli-types.gen.d.ts +18 -1
- package/dist/.pikku/cli/pikku-cli-types.gen.js +20 -1
- package/dist/.pikku/cli/pikku-cli-wirings-meta.gen.js +8 -116
- package/dist/.pikku/cli/pikku-cli-wirings.gen.d.ts +1 -2
- package/dist/.pikku/cli/pikku-cli-wirings.gen.js +1 -2
- package/dist/.pikku/function/pikku-function-types.gen.d.ts +1 -1
- package/dist/.pikku/function/pikku-function-types.gen.js +1 -1
- package/dist/.pikku/function/pikku-functions-meta.gen.js +265 -138
- package/dist/.pikku/function/pikku-functions-meta.min.gen.js +62 -32
- package/dist/.pikku/function/pikku-functions.gen.js +9 -1
- package/dist/.pikku/http/pikku-http-types.gen.d.ts +1 -1
- package/dist/.pikku/http/pikku-http-types.gen.js +1 -1
- package/dist/.pikku/http/pikku-http-wirings-meta.gen.js +1 -1
- package/dist/.pikku/http/pikku-http-wirings.gen.d.ts +1 -1
- package/dist/.pikku/http/pikku-http-wirings.gen.js +1 -1
- package/dist/.pikku/mcp/pikku-mcp-types.gen.d.ts +1 -1
- package/dist/.pikku/mcp/pikku-mcp-types.gen.js +1 -1
- package/dist/.pikku/mcp/pikku-mcp-wirings-meta.gen.js +1 -1
- package/dist/.pikku/mcp/pikku-mcp-wirings.gen.d.ts +1 -1
- package/dist/.pikku/mcp/pikku-mcp-wirings.gen.js +1 -1
- package/dist/.pikku/pikku-bootstrap.gen.d.ts +4 -1
- package/dist/.pikku/pikku-bootstrap.gen.js +4 -1
- package/dist/.pikku/pikku-services.gen.d.ts +15 -6
- package/dist/.pikku/pikku-services.gen.js +14 -2
- package/dist/.pikku/pikku-types.gen.d.ts +1 -1
- package/dist/.pikku/pikku-types.gen.js +1 -1
- package/dist/.pikku/pikku-websocket.gen.d.ts +15 -1
- package/dist/.pikku/pikku-websocket.gen.js +15 -1
- package/dist/.pikku/queue/pikku-queue-types.gen.d.ts +1 -1
- package/dist/.pikku/queue/pikku-queue-types.gen.js +1 -1
- package/dist/.pikku/queue/pikku-queue-workers-wirings-meta.gen.js +7 -2
- package/dist/.pikku/queue/pikku-queue-workers-wirings.gen.d.ts +1 -1
- package/dist/.pikku/queue/pikku-queue-workers-wirings.gen.js +1 -1
- package/dist/.pikku/rpc/pikku-remote-rpc-workers.gen.d.ts +17 -0
- package/dist/.pikku/rpc/pikku-remote-rpc-workers.gen.js +22 -0
- package/dist/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.js +15 -9
- package/dist/.pikku/scheduler/pikku-scheduler-types.gen.d.ts +1 -1
- package/dist/.pikku/scheduler/pikku-scheduler-types.gen.js +1 -1
- package/dist/.pikku/scheduler/pikku-schedulers-wirings-meta.gen.js +1 -1
- package/dist/.pikku/scheduler/pikku-schedulers-wirings.gen.d.ts +1 -1
- package/dist/.pikku/scheduler/pikku-schedulers-wirings.gen.js +1 -1
- package/dist/.pikku/schemas/register.gen.js +9 -3
- package/dist/.pikku/schemas/schemas/PikkuCLIConfig.schema.json +1 -1
- package/dist/.pikku/schemas/schemas/PikkuChannelsOutput.schema.json +1 -1
- package/dist/.pikku/schemas/schemas/PikkuPublicRPCOutput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/PikkuRemoteInternalRPCInput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/PikkuRemoteRPCOutput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/PikkuSchemasOutput.schema.json +1 -1
- package/dist/.pikku/schemas/schemas/PikkuWorkflowOutput.schema.json +1 -0
- package/dist/.pikku/workflow/pikku-workflow-types.gen.d.ts +58 -0
- package/dist/.pikku/workflow/pikku-workflow-types.gen.js +28 -0
- package/dist/.pikku/workflow/pikku-workflow-wirings-meta.gen.js +5 -0
- package/dist/.pikku/workflow/pikku-workflow-wirings.gen.d.ts +4 -0
- package/dist/.pikku/workflow/pikku-workflow-wirings.gen.js +5 -0
- package/dist/bin/pikku.js +24 -19
- package/dist/src/cli.wiring.js +107 -99
- package/dist/src/functions/commands/all.js +51 -2
- package/dist/src/functions/commands/bootstrap.d.ts +1 -0
- package/dist/src/functions/commands/bootstrap.js +24 -0
- package/dist/src/functions/runtimes/nextjs/serialize-nextjs-backend-wrapper.js +46 -2
- package/dist/src/functions/wirings/channels/serialize-channel-types.js +3 -2
- package/dist/src/functions/wirings/channels/serialize-websocket-wrapper.js +14 -0
- package/dist/src/functions/wirings/cli/pikku-command-cli-entry.js +4 -4
- package/dist/src/functions/wirings/cli/serialize-channel-cli-client.js +20 -7
- package/dist/src/functions/wirings/cli/serialize-channel-cli.js +32 -7
- package/dist/src/functions/wirings/cli/serialize-cli-types.js +22 -0
- package/dist/src/functions/wirings/functions/pikku-command-services.d.ts +1 -1
- package/dist/src/functions/wirings/functions/pikku-command-services.js +54 -26
- package/dist/src/functions/wirings/functions/schemas.js +2 -2
- package/dist/src/functions/wirings/http/pikku-command-openapi.js +1 -1
- package/dist/src/functions/wirings/middleware/pikku-command-middleware.js +3 -10
- package/dist/src/functions/wirings/queue/pikku-queue.js +9 -1
- package/dist/src/functions/wirings/queue/serialize-queue-map.d.ts +2 -2
- package/dist/src/functions/wirings/queue/serialize-queue-meta.d.ts +2 -2
- package/dist/src/functions/wirings/rpc/pikku-command-public-rpc.d.ts +1 -0
- package/dist/src/functions/wirings/rpc/pikku-command-public-rpc.js +23 -0
- package/dist/src/functions/wirings/rpc/pikku-command-remote-rpc.d.ts +1 -0
- package/dist/src/functions/wirings/rpc/pikku-command-remote-rpc.js +23 -0
- package/dist/src/functions/wirings/rpc/serialize-public-rpc.d.ts +4 -0
- package/dist/src/functions/wirings/rpc/serialize-public-rpc.js +30 -0
- package/dist/src/functions/wirings/rpc/serialize-remote-rpc.d.ts +4 -0
- package/dist/src/functions/wirings/rpc/serialize-remote-rpc.js +30 -0
- package/dist/src/functions/wirings/rpc/serialize-rpc-wrapper.js +2 -2
- package/dist/src/functions/wirings/rpc/serialize-typed-rpc-map.js +27 -3
- package/dist/src/functions/wirings/workflow/pikku-command-workflow-map.d.ts +1 -0
- package/dist/src/functions/wirings/workflow/pikku-command-workflow-map.js +12 -0
- package/dist/src/functions/wirings/workflow/pikku-command-workflow-types.d.ts +1 -0
- package/dist/src/functions/wirings/workflow/pikku-command-workflow-types.js +11 -0
- package/dist/src/functions/wirings/workflow/pikku-command-workflow.d.ts +1 -0
- package/dist/src/functions/wirings/workflow/pikku-command-workflow.js +55 -0
- package/dist/src/functions/wirings/workflow/serialize-workflow-map.d.ts +4 -0
- package/dist/src/functions/wirings/workflow/serialize-workflow-map.js +79 -0
- package/dist/src/functions/wirings/workflow/serialize-workflow-meta.d.ts +2 -0
- package/dist/src/functions/wirings/workflow/serialize-workflow-meta.js +10 -0
- package/dist/src/functions/wirings/workflow/serialize-workflow-types.d.ts +4 -0
- package/dist/src/functions/wirings/workflow/serialize-workflow-types.js +95 -0
- package/dist/src/functions/wirings/workflow/serialize-workflow-workers.d.ts +4 -0
- package/dist/src/functions/wirings/workflow/serialize-workflow-workers.js +60 -0
- package/dist/src/middleware/log-command-info-and-time.d.ts +1 -1
- package/dist/src/middleware/log-command-info-and-time.js +8 -5
- package/dist/src/services/cli-logger-forwarder.service.js +1 -1
- package/dist/src/services/cli-logger.service.d.ts +7 -2
- package/dist/src/services/cli-logger.service.js +17 -5
- package/dist/src/services.js +77 -12
- package/dist/src/utils/command-summary.d.ts +44 -0
- package/dist/src/utils/command-summary.js +74 -0
- package/dist/src/utils/file-writer.js +2 -2
- package/dist/src/utils/pikku-cli-config.js +48 -0
- package/dist/src/utils/schema-generator.d.ts +2 -2
- package/dist/src/utils/schema-generator.js +31 -10
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +3 -4
- package/pikku.config.json +5 -2
- package/src/cli.wiring.ts +106 -101
- package/src/functions/commands/all.ts +66 -2
- package/src/functions/commands/bootstrap.ts +28 -0
- package/src/functions/runtimes/nextjs/serialize-nextjs-backend-wrapper.ts +46 -2
- package/src/functions/wirings/channels/serialize-channel-types.ts +3 -2
- package/src/functions/wirings/channels/serialize-websocket-wrapper.ts +14 -0
- package/src/functions/wirings/cli/pikku-command-cli-entry.ts +4 -4
- package/src/functions/wirings/cli/serialize-channel-cli-client.ts +20 -7
- package/src/functions/wirings/cli/serialize-channel-cli.ts +40 -8
- package/src/functions/wirings/cli/serialize-cli-types.ts +22 -0
- package/src/functions/wirings/functions/pikku-command-services.ts +57 -28
- package/src/functions/wirings/functions/schemas.ts +4 -3
- package/src/functions/wirings/http/pikku-command-openapi.ts +2 -1
- package/src/functions/wirings/middleware/pikku-command-middleware.ts +11 -22
- package/src/functions/wirings/queue/pikku-queue.ts +10 -1
- package/src/functions/wirings/queue/serialize-queue-map.ts +3 -3
- package/src/functions/wirings/queue/serialize-queue-meta.ts +2 -2
- package/src/functions/wirings/rpc/pikku-command-public-rpc.ts +32 -0
- package/src/functions/wirings/rpc/pikku-command-remote-rpc.ts +35 -0
- package/src/functions/wirings/rpc/serialize-public-rpc.ts +30 -0
- package/src/functions/wirings/rpc/serialize-remote-rpc.ts +30 -0
- package/src/functions/wirings/rpc/serialize-rpc-wrapper.ts +2 -2
- package/src/functions/wirings/rpc/serialize-typed-rpc-map.ts +26 -3
- package/src/functions/wirings/workflow/pikku-command-workflow-map.ts +24 -0
- package/src/functions/wirings/workflow/pikku-command-workflow-types.ts +22 -0
- package/src/functions/wirings/workflow/pikku-command-workflow.ts +123 -0
- package/src/functions/wirings/workflow/serialize-workflow-map.ts +123 -0
- package/src/functions/wirings/workflow/serialize-workflow-meta.ts +16 -0
- package/src/functions/wirings/workflow/serialize-workflow-types.ts +95 -0
- package/src/functions/wirings/workflow/serialize-workflow-workers.ts +60 -0
- package/src/middleware/log-command-info-and-time.ts +8 -5
- package/src/services/cli-logger-forwarder.service.ts +1 -1
- package/src/services/cli-logger.service.ts +21 -6
- package/src/services.ts +86 -11
- package/src/utils/command-summary.ts +103 -0
- package/src/utils/file-writer.ts +2 -2
- package/src/utils/pikku-cli-config.ts +68 -0
- package/src/utils/schema-generator.ts +30 -11
- package/types/application-types.d.ts +5 -1
- package/types/config.d.ts +61 -6
- package/.pikku/cli/pikku-cli-channel.gen.ts +0 -34
- package/.pikku/cli/pikku-cli-client.gen.ts +0 -43
- package/.pikku/cli/pikku-cli.gen.ts +0 -41
- package/dist/.pikku/cli/pikku-cli-channel.gen.js +0 -33
- package/dist/.pikku/cli/pikku-cli-client.gen.d.ts +0 -10
- package/dist/.pikku/cli/pikku-cli-client.gen.js +0 -34
- package/dist/.pikku/cli/pikku-cli.gen.d.ts +0 -10
- package/dist/.pikku/cli/pikku-cli.gen.js +0 -38
- /package/dist/.pikku/{cli/pikku-cli-channel.gen.d.ts → workflow/pikku-workflow-wirings-meta.gen.d.ts} +0 -0
package/types/config.d.ts
CHANGED
|
@@ -46,6 +46,13 @@ export interface PikkuCLICoreOutputFiles {
|
|
|
46
46
|
queueMapDeclarationFile: string
|
|
47
47
|
queueTypesFile: string
|
|
48
48
|
|
|
49
|
+
// Workflows
|
|
50
|
+
workflowsWiringFile: string
|
|
51
|
+
workflowsWiringMetaFile: string
|
|
52
|
+
workflowsWorkersFile: string
|
|
53
|
+
workflowMapDeclarationFile: string
|
|
54
|
+
workflowTypesFile: string
|
|
55
|
+
|
|
49
56
|
// MCP
|
|
50
57
|
mcpWiringsFile: string
|
|
51
58
|
mcpWiringsMetaFile: string
|
|
@@ -78,8 +85,8 @@ export type PikkuCLIInput = {
|
|
|
78
85
|
|
|
79
86
|
rootDir: string
|
|
80
87
|
srcDirectories: string[]
|
|
88
|
+
ignoreFiles?: string[]
|
|
81
89
|
packageMappings: Record<string, string>
|
|
82
|
-
supportsImportAttributes: boolean
|
|
83
90
|
|
|
84
91
|
configDir: string
|
|
85
92
|
tsconfig: string
|
|
@@ -97,11 +104,16 @@ export type PikkuCLIInput = {
|
|
|
97
104
|
additionalInfo: OpenAPISpecInfo
|
|
98
105
|
}
|
|
99
106
|
|
|
107
|
+
schema?: {
|
|
108
|
+
additionalProperties?: boolean
|
|
109
|
+
supportsImportAttributes?: boolean
|
|
110
|
+
}
|
|
111
|
+
|
|
100
112
|
cli?: {
|
|
101
113
|
entrypoints?: Record<
|
|
102
114
|
string,
|
|
103
115
|
| string
|
|
104
|
-
| { type: '
|
|
116
|
+
| { type: 'local'; path: string }
|
|
105
117
|
| {
|
|
106
118
|
type: 'channel'
|
|
107
119
|
name?: string
|
|
@@ -111,7 +123,7 @@ export type PikkuCLIInput = {
|
|
|
111
123
|
}
|
|
112
124
|
| Array<
|
|
113
125
|
| string
|
|
114
|
-
| { type: '
|
|
126
|
+
| { type: 'local'; path: string }
|
|
115
127
|
| {
|
|
116
128
|
type: 'channel'
|
|
117
129
|
name?: string
|
|
@@ -123,6 +135,25 @@ export type PikkuCLIInput = {
|
|
|
123
135
|
>
|
|
124
136
|
}
|
|
125
137
|
|
|
138
|
+
workflows?:
|
|
139
|
+
| {
|
|
140
|
+
singleQueue: true
|
|
141
|
+
path: string
|
|
142
|
+
orchestratorQueue?: string
|
|
143
|
+
workerQueue?: string
|
|
144
|
+
}
|
|
145
|
+
| {
|
|
146
|
+
singleQueue: false
|
|
147
|
+
dir: string
|
|
148
|
+
orchestratorQueuePrefix?: string
|
|
149
|
+
workerQueuePrefix?: string
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
rpc?: {
|
|
153
|
+
remoteRpcWorkersPath?: string
|
|
154
|
+
publicRpcPath?: string
|
|
155
|
+
}
|
|
156
|
+
|
|
126
157
|
forceRequiredServices?: string[]
|
|
127
158
|
|
|
128
159
|
schemasFromTypes?: string[]
|
|
@@ -140,8 +171,8 @@ export type PikkuCLIConfig = {
|
|
|
140
171
|
|
|
141
172
|
rootDir: string
|
|
142
173
|
srcDirectories: string[]
|
|
174
|
+
ignoreFiles?: string[]
|
|
143
175
|
packageMappings: Record<string, string>
|
|
144
|
-
supportsImportAttributes: boolean
|
|
145
176
|
|
|
146
177
|
configFile?: string
|
|
147
178
|
tags?: string[]
|
|
@@ -167,11 +198,16 @@ export type PikkuCLIConfig = {
|
|
|
167
198
|
additionalInfo: OpenAPISpecInfo
|
|
168
199
|
}
|
|
169
200
|
|
|
201
|
+
schema?: {
|
|
202
|
+
additionalProperties?: boolean
|
|
203
|
+
supportsImportAttributes?: boolean
|
|
204
|
+
}
|
|
205
|
+
|
|
170
206
|
cli?: {
|
|
171
207
|
entrypoints?: Record<
|
|
172
208
|
string,
|
|
173
209
|
| string
|
|
174
|
-
| { type: '
|
|
210
|
+
| { type: 'local'; path: string }
|
|
175
211
|
| {
|
|
176
212
|
type: 'channel'
|
|
177
213
|
name?: string
|
|
@@ -181,7 +217,7 @@ export type PikkuCLIConfig = {
|
|
|
181
217
|
}
|
|
182
218
|
| Array<
|
|
183
219
|
| string
|
|
184
|
-
| { type: '
|
|
220
|
+
| { type: 'local'; path: string }
|
|
185
221
|
| {
|
|
186
222
|
type: 'channel'
|
|
187
223
|
name?: string
|
|
@@ -193,6 +229,25 @@ export type PikkuCLIConfig = {
|
|
|
193
229
|
>
|
|
194
230
|
}
|
|
195
231
|
|
|
232
|
+
workflows?:
|
|
233
|
+
| {
|
|
234
|
+
singleQueue: true
|
|
235
|
+
path: string
|
|
236
|
+
orchestratorQueue?: string
|
|
237
|
+
workerQueue?: string
|
|
238
|
+
}
|
|
239
|
+
| {
|
|
240
|
+
singleQueue: false
|
|
241
|
+
dir: string
|
|
242
|
+
orchestratorQueuePrefix?: string
|
|
243
|
+
workerQueuePrefix?: string
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
rpc?: {
|
|
247
|
+
remoteRpcWorkersPath?: string
|
|
248
|
+
publicRpcPath?: string
|
|
249
|
+
}
|
|
250
|
+
|
|
196
251
|
forceRequiredServices?: string[]
|
|
197
252
|
|
|
198
253
|
schemasFromTypes?: string[]
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file was generated by @pikku/cli@0.10.1
|
|
3
|
-
*/
|
|
4
|
-
/**
|
|
5
|
-
* WebSocket channel backend for 'pikku' CLI commands
|
|
6
|
-
*/
|
|
7
|
-
import { wireChannel } from '../channel/pikku-channel-types.gen.js'
|
|
8
|
-
import { all } from '../../src/functions/commands/all.js'
|
|
9
|
-
import { pikkuSchemas } from '../../src/functions/wirings/functions/schemas.js'
|
|
10
|
-
import { pikkuFetch } from '../../src/functions/wirings/fetch/index.js'
|
|
11
|
-
import { pikkuWebSocketTyped } from '../../src/functions/wirings/channels/pikku-command-websocket-typed.js'
|
|
12
|
-
import { pikkuRPCClient } from '../../src/functions/wirings/rpc/pikku-command-rpc-client.js'
|
|
13
|
-
import { pikkuQueueService } from '../../src/functions/wirings/queue/pikku-command-queue-service.js'
|
|
14
|
-
import { pikkuOpenAPI } from '../../src/functions/wirings/http/pikku-command-openapi.js'
|
|
15
|
-
import { pikkuNext } from '../../src/functions/runtimes/nextjs/pikku-command-nextjs.js'
|
|
16
|
-
|
|
17
|
-
wireChannel({
|
|
18
|
-
name: 'pikku-cli',
|
|
19
|
-
route: '/cli/pikku',
|
|
20
|
-
auth: false,
|
|
21
|
-
onMessageWiring: {
|
|
22
|
-
command: {
|
|
23
|
-
'all': all,
|
|
24
|
-
'schemas': pikkuSchemas,
|
|
25
|
-
'fetch': pikkuFetch,
|
|
26
|
-
'websocket': pikkuWebSocketTyped,
|
|
27
|
-
'rpc': pikkuRPCClient,
|
|
28
|
-
'queue-service': pikkuQueueService,
|
|
29
|
-
'openapi': pikkuOpenAPI,
|
|
30
|
-
'nextjs': pikkuNext
|
|
31
|
-
}
|
|
32
|
-
},
|
|
33
|
-
tags: ['cli', 'pikku']
|
|
34
|
-
})
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file was generated by @pikku/cli@0.10.1
|
|
3
|
-
*/
|
|
4
|
-
|
|
5
|
-
import { executeCLIViaChannel } from '@pikku/core/cli/channel'
|
|
6
|
-
import { CorePikkuWebsocket } from '@pikku/websocket'
|
|
7
|
-
import '../pikku-bootstrap.gen.js'
|
|
8
|
-
import { clientCLIRenderer } from '../../src/services.js'
|
|
9
|
-
|
|
10
|
-
/**
|
|
11
|
-
* Pikku CLI Client (via WebSocket Channel)
|
|
12
|
-
* Executes CLI commands over a WebSocket connection
|
|
13
|
-
*/
|
|
14
|
-
export async function PikkuCLIClient(
|
|
15
|
-
url: string,
|
|
16
|
-
args?: string[]
|
|
17
|
-
): Promise<void> {
|
|
18
|
-
// Create WebSocket connection
|
|
19
|
-
const pikkuWS = new CorePikkuWebsocket(url)
|
|
20
|
-
|
|
21
|
-
// Register renderers for CLI commands
|
|
22
|
-
const renderers = {}
|
|
23
|
-
|
|
24
|
-
await executeCLIViaChannel({
|
|
25
|
-
programName: 'pikku',
|
|
26
|
-
pikkuWS,
|
|
27
|
-
args,
|
|
28
|
-
renderers,
|
|
29
|
-
defaultRenderer: clientCLIRenderer,
|
|
30
|
-
})
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
// Export as default for easy importing
|
|
34
|
-
export default PikkuCLIClient
|
|
35
|
-
|
|
36
|
-
// For direct execution (if this file is run directly)
|
|
37
|
-
if (import.meta.url === `file://${process.argv[1]}`) {
|
|
38
|
-
const url = process.env.PIKKU_WS_URL || 'ws://localhost:3000/cli/pikku'
|
|
39
|
-
PikkuCLIClient(url, process.argv.slice(2)).catch(error => {
|
|
40
|
-
console.error('Fatal error:', error.message)
|
|
41
|
-
process.exit(1)
|
|
42
|
-
})
|
|
43
|
-
}
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file was generated by @pikku/cli@0.10.1
|
|
3
|
-
*/
|
|
4
|
-
|
|
5
|
-
import { executeCLI, CLIError } from '@pikku/core/cli'
|
|
6
|
-
import { createConfig as createConfig } from '../../src/services.js'
|
|
7
|
-
import { createSingletonServices as createSingletonServices } from '../../src/services.js'
|
|
8
|
-
import { createSessionServices as createSessionServices } from '../../src/services.js'
|
|
9
|
-
import '../pikku-bootstrap.gen.js'
|
|
10
|
-
|
|
11
|
-
/**
|
|
12
|
-
* Pikku CLI function
|
|
13
|
-
* Handles command line arguments and executes the appropriate function
|
|
14
|
-
*/
|
|
15
|
-
export async function PikkuCLI(args: string[]): Promise<void> {
|
|
16
|
-
try {
|
|
17
|
-
await executeCLI({
|
|
18
|
-
programName: 'pikku',
|
|
19
|
-
args: args || process.argv.slice(2),
|
|
20
|
-
createConfig,
|
|
21
|
-
createSingletonServices,
|
|
22
|
-
createSessionServices,
|
|
23
|
-
})
|
|
24
|
-
} catch (error) {
|
|
25
|
-
if (error instanceof CLIError) {
|
|
26
|
-
process.exit(error.exitCode)
|
|
27
|
-
}
|
|
28
|
-
throw error
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
// Export as default for easy importing
|
|
33
|
-
export default PikkuCLI
|
|
34
|
-
|
|
35
|
-
// For direct execution (if this file is run directly)
|
|
36
|
-
if (import.meta.url === `file://${process.argv[1]}`) {
|
|
37
|
-
PikkuCLI(process.argv.slice(2)).catch(error => {
|
|
38
|
-
console.error('Fatal error:', error.message)
|
|
39
|
-
process.exit(1)
|
|
40
|
-
})
|
|
41
|
-
}
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file was generated by @pikku/cli@0.10.1
|
|
3
|
-
*/
|
|
4
|
-
/**
|
|
5
|
-
* WebSocket channel backend for 'pikku' CLI commands
|
|
6
|
-
*/
|
|
7
|
-
import { wireChannel } from '../channel/pikku-channel-types.gen.js';
|
|
8
|
-
import { all } from '../../src/functions/commands/all.js';
|
|
9
|
-
import { pikkuSchemas } from '../../src/functions/wirings/functions/schemas.js';
|
|
10
|
-
import { pikkuFetch } from '../../src/functions/wirings/fetch/index.js';
|
|
11
|
-
import { pikkuWebSocketTyped } from '../../src/functions/wirings/channels/pikku-command-websocket-typed.js';
|
|
12
|
-
import { pikkuRPCClient } from '../../src/functions/wirings/rpc/pikku-command-rpc-client.js';
|
|
13
|
-
import { pikkuQueueService } from '../../src/functions/wirings/queue/pikku-command-queue-service.js';
|
|
14
|
-
import { pikkuOpenAPI } from '../../src/functions/wirings/http/pikku-command-openapi.js';
|
|
15
|
-
import { pikkuNext } from '../../src/functions/runtimes/nextjs/pikku-command-nextjs.js';
|
|
16
|
-
wireChannel({
|
|
17
|
-
name: 'pikku-cli',
|
|
18
|
-
route: '/cli/pikku',
|
|
19
|
-
auth: false,
|
|
20
|
-
onMessageWiring: {
|
|
21
|
-
command: {
|
|
22
|
-
'all': all,
|
|
23
|
-
'schemas': pikkuSchemas,
|
|
24
|
-
'fetch': pikkuFetch,
|
|
25
|
-
'websocket': pikkuWebSocketTyped,
|
|
26
|
-
'rpc': pikkuRPCClient,
|
|
27
|
-
'queue-service': pikkuQueueService,
|
|
28
|
-
'openapi': pikkuOpenAPI,
|
|
29
|
-
'nextjs': pikkuNext
|
|
30
|
-
}
|
|
31
|
-
},
|
|
32
|
-
tags: ['cli', 'pikku']
|
|
33
|
-
});
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file was generated by @pikku/cli@0.10.1
|
|
3
|
-
*/
|
|
4
|
-
import '../pikku-bootstrap.gen.js';
|
|
5
|
-
/**
|
|
6
|
-
* Pikku CLI Client (via WebSocket Channel)
|
|
7
|
-
* Executes CLI commands over a WebSocket connection
|
|
8
|
-
*/
|
|
9
|
-
export declare function PikkuCLIClient(url: string, args?: string[]): Promise<void>;
|
|
10
|
-
export default PikkuCLIClient;
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file was generated by @pikku/cli@0.10.1
|
|
3
|
-
*/
|
|
4
|
-
import { executeCLIViaChannel } from '@pikku/core/cli/channel';
|
|
5
|
-
import { CorePikkuWebsocket } from '@pikku/websocket';
|
|
6
|
-
import '../pikku-bootstrap.gen.js';
|
|
7
|
-
import { clientCLIRenderer } from '../../src/services.js';
|
|
8
|
-
/**
|
|
9
|
-
* Pikku CLI Client (via WebSocket Channel)
|
|
10
|
-
* Executes CLI commands over a WebSocket connection
|
|
11
|
-
*/
|
|
12
|
-
export async function PikkuCLIClient(url, args) {
|
|
13
|
-
// Create WebSocket connection
|
|
14
|
-
const pikkuWS = new CorePikkuWebsocket(url);
|
|
15
|
-
// Register renderers for CLI commands
|
|
16
|
-
const renderers = {};
|
|
17
|
-
await executeCLIViaChannel({
|
|
18
|
-
programName: 'pikku',
|
|
19
|
-
pikkuWS,
|
|
20
|
-
args,
|
|
21
|
-
renderers,
|
|
22
|
-
defaultRenderer: clientCLIRenderer,
|
|
23
|
-
});
|
|
24
|
-
}
|
|
25
|
-
// Export as default for easy importing
|
|
26
|
-
export default PikkuCLIClient;
|
|
27
|
-
// For direct execution (if this file is run directly)
|
|
28
|
-
if (import.meta.url === `file://${process.argv[1]}`) {
|
|
29
|
-
const url = process.env.PIKKU_WS_URL || 'ws://localhost:3000/cli/pikku';
|
|
30
|
-
PikkuCLIClient(url, process.argv.slice(2)).catch(error => {
|
|
31
|
-
console.error('Fatal error:', error.message);
|
|
32
|
-
process.exit(1);
|
|
33
|
-
});
|
|
34
|
-
}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file was generated by @pikku/cli@0.10.1
|
|
3
|
-
*/
|
|
4
|
-
import '../pikku-bootstrap.gen.js';
|
|
5
|
-
/**
|
|
6
|
-
* Pikku CLI function
|
|
7
|
-
* Handles command line arguments and executes the appropriate function
|
|
8
|
-
*/
|
|
9
|
-
export declare function PikkuCLI(args: string[]): Promise<void>;
|
|
10
|
-
export default PikkuCLI;
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file was generated by @pikku/cli@0.10.1
|
|
3
|
-
*/
|
|
4
|
-
import { executeCLI, CLIError } from '@pikku/core/cli';
|
|
5
|
-
import { createConfig as createConfig } from '../../src/services.js';
|
|
6
|
-
import { createSingletonServices as createSingletonServices } from '../../src/services.js';
|
|
7
|
-
import { createSessionServices as createSessionServices } from '../../src/services.js';
|
|
8
|
-
import '../pikku-bootstrap.gen.js';
|
|
9
|
-
/**
|
|
10
|
-
* Pikku CLI function
|
|
11
|
-
* Handles command line arguments and executes the appropriate function
|
|
12
|
-
*/
|
|
13
|
-
export async function PikkuCLI(args) {
|
|
14
|
-
try {
|
|
15
|
-
await executeCLI({
|
|
16
|
-
programName: 'pikku',
|
|
17
|
-
args: args || process.argv.slice(2),
|
|
18
|
-
createConfig,
|
|
19
|
-
createSingletonServices,
|
|
20
|
-
createSessionServices,
|
|
21
|
-
});
|
|
22
|
-
}
|
|
23
|
-
catch (error) {
|
|
24
|
-
if (error instanceof CLIError) {
|
|
25
|
-
process.exit(error.exitCode);
|
|
26
|
-
}
|
|
27
|
-
throw error;
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
// Export as default for easy importing
|
|
31
|
-
export default PikkuCLI;
|
|
32
|
-
// For direct execution (if this file is run directly)
|
|
33
|
-
if (import.meta.url === `file://${process.argv[1]}`) {
|
|
34
|
-
PikkuCLI(process.argv.slice(2)).catch(error => {
|
|
35
|
-
console.error('Fatal error:', error.message);
|
|
36
|
-
process.exit(1);
|
|
37
|
-
});
|
|
38
|
-
}
|
|
File without changes
|