@camunda8/cli 2.0.0-alpha.1 → 2.0.0-alpha.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +72 -5
- package/dist/commands/completion.d.ts +8 -0
- package/dist/commands/completion.d.ts.map +1 -0
- package/dist/commands/completion.js +596 -0
- package/dist/commands/completion.js.map +1 -0
- package/dist/commands/help.d.ts.map +1 -1
- package/dist/commands/help.js +12 -4
- package/dist/commands/help.js.map +1 -1
- package/dist/commands/process-definitions.d.ts +17 -0
- package/dist/commands/process-definitions.d.ts.map +1 -0
- package/dist/commands/process-definitions.js +61 -0
- package/dist/commands/process-definitions.js.map +1 -0
- package/dist/commands/profiles.d.ts +17 -8
- package/dist/commands/profiles.d.ts.map +1 -1
- package/dist/commands/profiles.js +74 -35
- package/dist/commands/profiles.js.map +1 -1
- package/dist/commands/session.js +3 -3
- package/dist/commands/session.js.map +1 -1
- package/dist/config.d.ts +104 -49
- package/dist/config.d.ts.map +1 -1
- package/dist/config.js +306 -164
- package/dist/config.js.map +1 -1
- package/dist/index.js +30 -3
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,596 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Shell completion commands
|
|
3
|
+
*/
|
|
4
|
+
import { getLogger } from "../logger.js";
|
|
5
|
+
/**
|
|
6
|
+
* Generate bash completion script
|
|
7
|
+
*/
|
|
8
|
+
function generateBashCompletion() {
|
|
9
|
+
return `# c8ctl bash completion
|
|
10
|
+
_c8ctl_completions() {
|
|
11
|
+
local cur prev words cword
|
|
12
|
+
|
|
13
|
+
# Initialize completion variables (standalone, no bash-completion dependency)
|
|
14
|
+
COMPREPLY=()
|
|
15
|
+
cur="\${COMP_WORDS[COMP_CWORD]}"
|
|
16
|
+
prev="\${COMP_WORDS[COMP_CWORD-1]}"
|
|
17
|
+
words=("\${COMP_WORDS[@]}")
|
|
18
|
+
cword=\${COMP_CWORD}
|
|
19
|
+
|
|
20
|
+
# Commands (verbs)
|
|
21
|
+
local verbs="list get create cancel complete fail activate resolve publish correlate deploy run watch add remove rm load unload use output completion help"
|
|
22
|
+
|
|
23
|
+
# Resources by verb
|
|
24
|
+
local list_resources="process-instances process-instance pi user-tasks user-task ut incidents incident inc jobs profiles profile plugins plugin"
|
|
25
|
+
local get_resources="process-instance pi topology"
|
|
26
|
+
local create_resources="process-instance pi"
|
|
27
|
+
local cancel_resources="process-instance pi"
|
|
28
|
+
local complete_resources="user-task ut job"
|
|
29
|
+
local fail_resources="job"
|
|
30
|
+
local activate_resources="jobs"
|
|
31
|
+
local resolve_resources="incident inc"
|
|
32
|
+
local publish_resources="message msg"
|
|
33
|
+
local correlate_resources="message msg"
|
|
34
|
+
local add_resources="profile"
|
|
35
|
+
local remove_resources="profile"
|
|
36
|
+
local load_resources="plugin"
|
|
37
|
+
local unload_resources="plugin"
|
|
38
|
+
local use_resources="profile tenant"
|
|
39
|
+
local output_resources="json text"
|
|
40
|
+
local completion_resources="bash zsh fish"
|
|
41
|
+
|
|
42
|
+
# Global flags
|
|
43
|
+
local flags="--help --version --profile --from --all --bpmnProcessId --processInstanceKey --variables --state --assignee --type --correlationKey --timeToLive --maxJobsToActivate --timeout --worker --retries --errorMessage --baseUrl --clientId --clientSecret --audience --oAuthUrl --defaultTenantId --version_num"
|
|
44
|
+
|
|
45
|
+
case \${cword} in
|
|
46
|
+
1)
|
|
47
|
+
# Complete verbs
|
|
48
|
+
COMPREPLY=( \$(compgen -W "\${verbs}" -- "\${cur}") )
|
|
49
|
+
;;
|
|
50
|
+
2)
|
|
51
|
+
# Complete resources based on verb
|
|
52
|
+
local verb="\${words[1]}"
|
|
53
|
+
case "\${verb}" in
|
|
54
|
+
list)
|
|
55
|
+
COMPREPLY=( \$(compgen -W "\${list_resources}" -- "\${cur}") )
|
|
56
|
+
;;
|
|
57
|
+
get)
|
|
58
|
+
COMPREPLY=( \$(compgen -W "\${get_resources}" -- "\${cur}") )
|
|
59
|
+
;;
|
|
60
|
+
create)
|
|
61
|
+
COMPREPLY=( \$(compgen -W "\${create_resources}" -- "\${cur}") )
|
|
62
|
+
;;
|
|
63
|
+
cancel)
|
|
64
|
+
COMPREPLY=( \$(compgen -W "\${cancel_resources}" -- "\${cur}") )
|
|
65
|
+
;;
|
|
66
|
+
complete)
|
|
67
|
+
COMPREPLY=( \$(compgen -W "\${complete_resources}" -- "\${cur}") )
|
|
68
|
+
;;
|
|
69
|
+
fail)
|
|
70
|
+
COMPREPLY=( \$(compgen -W "\${fail_resources}" -- "\${cur}") )
|
|
71
|
+
;;
|
|
72
|
+
activate)
|
|
73
|
+
COMPREPLY=( \$(compgen -W "\${activate_resources}" -- "\${cur}") )
|
|
74
|
+
;;
|
|
75
|
+
resolve)
|
|
76
|
+
COMPREPLY=( \$(compgen -W "\${resolve_resources}" -- "\${cur}") )
|
|
77
|
+
;;
|
|
78
|
+
publish)
|
|
79
|
+
COMPREPLY=( \$(compgen -W "\${publish_resources}" -- "\${cur}") )
|
|
80
|
+
;;
|
|
81
|
+
correlate)
|
|
82
|
+
COMPREPLY=( \$(compgen -W "\${correlate_resources}" -- "\${cur}") )
|
|
83
|
+
;;
|
|
84
|
+
add)
|
|
85
|
+
COMPREPLY=( \$(compgen -W "\${add_resources}" -- "\${cur}") )
|
|
86
|
+
;;
|
|
87
|
+
remove|rm)
|
|
88
|
+
COMPREPLY=( \$(compgen -W "\${remove_resources}" -- "\${cur}") )
|
|
89
|
+
;;
|
|
90
|
+
load)
|
|
91
|
+
COMPREPLY=( \$(compgen -W "\${load_resources}" -- "\${cur}") )
|
|
92
|
+
;;
|
|
93
|
+
unload)
|
|
94
|
+
COMPREPLY=( \$(compgen -W "\${unload_resources}" -- "\${cur}") )
|
|
95
|
+
;;
|
|
96
|
+
use)
|
|
97
|
+
COMPREPLY=( \$(compgen -W "\${use_resources}" -- "\${cur}") )
|
|
98
|
+
;;
|
|
99
|
+
output)
|
|
100
|
+
COMPREPLY=( \$(compgen -W "\${output_resources}" -- "\${cur}") )
|
|
101
|
+
;;
|
|
102
|
+
completion)
|
|
103
|
+
COMPREPLY=( \$(compgen -W "\${completion_resources}" -- "\${cur}") )
|
|
104
|
+
;;
|
|
105
|
+
deploy|run|watch)
|
|
106
|
+
# Complete with files
|
|
107
|
+
COMPREPLY=( \$(compgen -f -- "\${cur}") )
|
|
108
|
+
;;
|
|
109
|
+
esac
|
|
110
|
+
;;
|
|
111
|
+
*)
|
|
112
|
+
# Complete flags or files
|
|
113
|
+
if [[ \${cur} == -* ]]; then
|
|
114
|
+
COMPREPLY=( \$(compgen -W "\${flags}" -- "\${cur}") )
|
|
115
|
+
else
|
|
116
|
+
COMPREPLY=( \$(compgen -f -- "\${cur}") )
|
|
117
|
+
fi
|
|
118
|
+
;;
|
|
119
|
+
esac
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
complete -F _c8ctl_completions c8ctl
|
|
123
|
+
complete -F _c8ctl_completions c8
|
|
124
|
+
`;
|
|
125
|
+
}
|
|
126
|
+
/**
|
|
127
|
+
* Generate zsh completion script
|
|
128
|
+
*/
|
|
129
|
+
function generateZshCompletion() {
|
|
130
|
+
return `#compdef c8ctl c8
|
|
131
|
+
|
|
132
|
+
_c8ctl() {
|
|
133
|
+
local -a verbs resources flags
|
|
134
|
+
|
|
135
|
+
verbs=(
|
|
136
|
+
'list:List resources'
|
|
137
|
+
'get:Get resource by key'
|
|
138
|
+
'create:Create resource'
|
|
139
|
+
'cancel:Cancel resource'
|
|
140
|
+
'complete:Complete resource'
|
|
141
|
+
'fail:Fail a job'
|
|
142
|
+
'activate:Activate jobs by type'
|
|
143
|
+
'resolve:Resolve incident'
|
|
144
|
+
'publish:Publish message'
|
|
145
|
+
'correlate:Correlate message'
|
|
146
|
+
'deploy:Deploy BPMN/DMN/forms'
|
|
147
|
+
'run:Deploy and start process'
|
|
148
|
+
'watch:Watch files for changes and auto-deploy'
|
|
149
|
+
'add:Add a profile'
|
|
150
|
+
'remove:Remove a profile'
|
|
151
|
+
'rm:Remove a profile'
|
|
152
|
+
'load:Load a c8ctl plugin'
|
|
153
|
+
'unload:Unload a c8ctl plugin'
|
|
154
|
+
'use:Set active profile or tenant'
|
|
155
|
+
'output:Set output format'
|
|
156
|
+
'completion:Generate shell completion script'
|
|
157
|
+
'help:Show help'
|
|
158
|
+
)
|
|
159
|
+
|
|
160
|
+
flags=(
|
|
161
|
+
'--help[Show help]'
|
|
162
|
+
'-h[Show help]'
|
|
163
|
+
'--version[Show version]'
|
|
164
|
+
'-v[Show version]'
|
|
165
|
+
'--profile[Use specific profile]:profile:'
|
|
166
|
+
'--from[Load plugin from URL]:url:'
|
|
167
|
+
'--all[Show all results]'
|
|
168
|
+
'--bpmnProcessId[Process definition ID]:id:'
|
|
169
|
+
'--processInstanceKey[Process instance key]:key:'
|
|
170
|
+
'--variables[JSON variables]:json:'
|
|
171
|
+
'--state[Filter by state]:state:'
|
|
172
|
+
'--assignee[Filter by assignee]:assignee:'
|
|
173
|
+
'--type[Job type]:type:'
|
|
174
|
+
'--correlationKey[Message correlation key]:key:'
|
|
175
|
+
'--timeToLive[Message TTL in ms]:ttl:'
|
|
176
|
+
'--maxJobsToActivate[Maximum jobs to activate]:count:'
|
|
177
|
+
'--timeout[Job timeout in ms]:timeout:'
|
|
178
|
+
'--worker[Worker name]:name:'
|
|
179
|
+
'--retries[Number of retries]:count:'
|
|
180
|
+
'--errorMessage[Error message]:message:'
|
|
181
|
+
'--baseUrl[Cluster base URL]:url:'
|
|
182
|
+
'--clientId[OAuth client ID]:id:'
|
|
183
|
+
'--clientSecret[OAuth client secret]:secret:'
|
|
184
|
+
'--audience[OAuth audience]:audience:'
|
|
185
|
+
'--oAuthUrl[OAuth token endpoint]:url:'
|
|
186
|
+
'--defaultTenantId[Default tenant ID]:id:'
|
|
187
|
+
'--version_num[Process definition version]:version:'
|
|
188
|
+
)
|
|
189
|
+
|
|
190
|
+
case \$CURRENT in
|
|
191
|
+
2)
|
|
192
|
+
_describe 'command' verbs
|
|
193
|
+
;;
|
|
194
|
+
3)
|
|
195
|
+
case "\${words[2]}" in
|
|
196
|
+
list)
|
|
197
|
+
resources=(
|
|
198
|
+
'process-instances:List process instances'
|
|
199
|
+
'process-instance:List process instances'
|
|
200
|
+
'pi:List process instances'
|
|
201
|
+
'user-tasks:List user tasks'
|
|
202
|
+
'user-task:List user tasks'
|
|
203
|
+
'ut:List user tasks'
|
|
204
|
+
'incidents:List incidents'
|
|
205
|
+
'incident:List incidents'
|
|
206
|
+
'inc:List incidents'
|
|
207
|
+
'jobs:List jobs'
|
|
208
|
+
'profiles:List profiles'
|
|
209
|
+
'profile:List profiles'
|
|
210
|
+
'plugins:List plugins'
|
|
211
|
+
'plugin:List plugins'
|
|
212
|
+
)
|
|
213
|
+
_describe 'resource' resources
|
|
214
|
+
;;
|
|
215
|
+
get)
|
|
216
|
+
resources=(
|
|
217
|
+
'process-instance:Get process instance'
|
|
218
|
+
'pi:Get process instance'
|
|
219
|
+
'topology:Get cluster topology'
|
|
220
|
+
)
|
|
221
|
+
_describe 'resource' resources
|
|
222
|
+
;;
|
|
223
|
+
create)
|
|
224
|
+
resources=(
|
|
225
|
+
'process-instance:Create process instance'
|
|
226
|
+
'pi:Create process instance'
|
|
227
|
+
)
|
|
228
|
+
_describe 'resource' resources
|
|
229
|
+
;;
|
|
230
|
+
cancel)
|
|
231
|
+
resources=(
|
|
232
|
+
'process-instance:Cancel process instance'
|
|
233
|
+
'pi:Cancel process instance'
|
|
234
|
+
)
|
|
235
|
+
_describe 'resource' resources
|
|
236
|
+
;;
|
|
237
|
+
complete)
|
|
238
|
+
resources=(
|
|
239
|
+
'user-task:Complete user task'
|
|
240
|
+
'ut:Complete user task'
|
|
241
|
+
'job:Complete job'
|
|
242
|
+
)
|
|
243
|
+
_describe 'resource' resources
|
|
244
|
+
;;
|
|
245
|
+
fail)
|
|
246
|
+
resources=(
|
|
247
|
+
'job:Fail job'
|
|
248
|
+
)
|
|
249
|
+
_describe 'resource' resources
|
|
250
|
+
;;
|
|
251
|
+
activate)
|
|
252
|
+
resources=(
|
|
253
|
+
'jobs:Activate jobs'
|
|
254
|
+
)
|
|
255
|
+
_describe 'resource' resources
|
|
256
|
+
;;
|
|
257
|
+
resolve)
|
|
258
|
+
resources=(
|
|
259
|
+
'incident:Resolve incident'
|
|
260
|
+
'inc:Resolve incident'
|
|
261
|
+
)
|
|
262
|
+
_describe 'resource' resources
|
|
263
|
+
;;
|
|
264
|
+
publish)
|
|
265
|
+
resources=(
|
|
266
|
+
'message:Publish message'
|
|
267
|
+
'msg:Publish message'
|
|
268
|
+
)
|
|
269
|
+
_describe 'resource' resources
|
|
270
|
+
;;
|
|
271
|
+
correlate)
|
|
272
|
+
resources=(
|
|
273
|
+
'message:Correlate message'
|
|
274
|
+
'msg:Correlate message'
|
|
275
|
+
)
|
|
276
|
+
_describe 'resource' resources
|
|
277
|
+
;;
|
|
278
|
+
add)
|
|
279
|
+
resources=(
|
|
280
|
+
'profile:Add profile'
|
|
281
|
+
)
|
|
282
|
+
_describe 'resource' resources
|
|
283
|
+
;;
|
|
284
|
+
remove|rm)
|
|
285
|
+
resources=(
|
|
286
|
+
'profile:Remove profile'
|
|
287
|
+
)
|
|
288
|
+
_describe 'resource' resources
|
|
289
|
+
;;
|
|
290
|
+
load)
|
|
291
|
+
resources=(
|
|
292
|
+
'plugin:Load plugin'
|
|
293
|
+
)
|
|
294
|
+
_describe 'resource' resources
|
|
295
|
+
;;
|
|
296
|
+
unload)
|
|
297
|
+
resources=(
|
|
298
|
+
'plugin:Unload plugin'
|
|
299
|
+
)
|
|
300
|
+
_describe 'resource' resources
|
|
301
|
+
;;
|
|
302
|
+
use)
|
|
303
|
+
resources=(
|
|
304
|
+
'profile:Set active profile'
|
|
305
|
+
'tenant:Set active tenant'
|
|
306
|
+
)
|
|
307
|
+
_describe 'resource' resources
|
|
308
|
+
;;
|
|
309
|
+
output)
|
|
310
|
+
resources=(
|
|
311
|
+
'json:JSON output'
|
|
312
|
+
'text:Text output'
|
|
313
|
+
)
|
|
314
|
+
_describe 'resource' resources
|
|
315
|
+
;;
|
|
316
|
+
completion)
|
|
317
|
+
resources=(
|
|
318
|
+
'bash:Generate bash completion'
|
|
319
|
+
'zsh:Generate zsh completion'
|
|
320
|
+
'fish:Generate fish completion'
|
|
321
|
+
)
|
|
322
|
+
_describe 'resource' resources
|
|
323
|
+
;;
|
|
324
|
+
deploy|run|watch)
|
|
325
|
+
_files
|
|
326
|
+
;;
|
|
327
|
+
esac
|
|
328
|
+
;;
|
|
329
|
+
*)
|
|
330
|
+
_arguments \${flags[@]}
|
|
331
|
+
;;
|
|
332
|
+
esac
|
|
333
|
+
}
|
|
334
|
+
|
|
335
|
+
# compdef is handled by the #compdef directive at the top
|
|
336
|
+
`;
|
|
337
|
+
}
|
|
338
|
+
/**
|
|
339
|
+
* Generate fish completion script
|
|
340
|
+
*/
|
|
341
|
+
function generateFishCompletion() {
|
|
342
|
+
return `# c8ctl fish completion
|
|
343
|
+
|
|
344
|
+
# Remove all existing completions for c8ctl and c8
|
|
345
|
+
complete -c c8ctl -e
|
|
346
|
+
complete -c c8 -e
|
|
347
|
+
|
|
348
|
+
# Global flags
|
|
349
|
+
complete -c c8ctl -s h -l help -d 'Show help'
|
|
350
|
+
complete -c c8 -s h -l help -d 'Show help'
|
|
351
|
+
complete -c c8ctl -s v -l version -d 'Show version'
|
|
352
|
+
complete -c c8 -s v -l version -d 'Show version'
|
|
353
|
+
complete -c c8ctl -l profile -d 'Use specific profile' -r
|
|
354
|
+
complete -c c8 -l profile -d 'Use specific profile' -r
|
|
355
|
+
complete -c c8ctl -l from -d 'Load plugin from URL' -r
|
|
356
|
+
complete -c c8 -l from -d 'Load plugin from URL' -r
|
|
357
|
+
complete -c c8ctl -l all -d 'Show all results'
|
|
358
|
+
complete -c c8 -l all -d 'Show all results'
|
|
359
|
+
complete -c c8ctl -l bpmnProcessId -d 'Process definition ID' -r
|
|
360
|
+
complete -c c8 -l bpmnProcessId -d 'Process definition ID' -r
|
|
361
|
+
complete -c c8ctl -l processInstanceKey -d 'Process instance key' -r
|
|
362
|
+
complete -c c8 -l processInstanceKey -d 'Process instance key' -r
|
|
363
|
+
complete -c c8ctl -l variables -d 'JSON variables' -r
|
|
364
|
+
complete -c c8 -l variables -d 'JSON variables' -r
|
|
365
|
+
complete -c c8ctl -l state -d 'Filter by state' -r
|
|
366
|
+
complete -c c8 -l state -d 'Filter by state' -r
|
|
367
|
+
complete -c c8ctl -l assignee -d 'Filter by assignee' -r
|
|
368
|
+
complete -c c8 -l assignee -d 'Filter by assignee' -r
|
|
369
|
+
complete -c c8ctl -l type -d 'Job type' -r
|
|
370
|
+
complete -c c8 -l type -d 'Job type' -r
|
|
371
|
+
complete -c c8ctl -l correlationKey -d 'Message correlation key' -r
|
|
372
|
+
complete -c c8 -l correlationKey -d 'Message correlation key' -r
|
|
373
|
+
complete -c c8ctl -l timeToLive -d 'Message TTL in ms' -r
|
|
374
|
+
complete -c c8 -l timeToLive -d 'Message TTL in ms' -r
|
|
375
|
+
complete -c c8ctl -l maxJobsToActivate -d 'Maximum jobs to activate' -r
|
|
376
|
+
complete -c c8 -l maxJobsToActivate -d 'Maximum jobs to activate' -r
|
|
377
|
+
complete -c c8ctl -l timeout -d 'Job timeout in ms' -r
|
|
378
|
+
complete -c c8 -l timeout -d 'Job timeout in ms' -r
|
|
379
|
+
complete -c c8ctl -l worker -d 'Worker name' -r
|
|
380
|
+
complete -c c8 -l worker -d 'Worker name' -r
|
|
381
|
+
complete -c c8ctl -l retries -d 'Number of retries' -r
|
|
382
|
+
complete -c c8 -l retries -d 'Number of retries' -r
|
|
383
|
+
complete -c c8ctl -l errorMessage -d 'Error message' -r
|
|
384
|
+
complete -c c8 -l errorMessage -d 'Error message' -r
|
|
385
|
+
complete -c c8ctl -l baseUrl -d 'Cluster base URL' -r
|
|
386
|
+
complete -c c8 -l baseUrl -d 'Cluster base URL' -r
|
|
387
|
+
complete -c c8ctl -l clientId -d 'OAuth client ID' -r
|
|
388
|
+
complete -c c8 -l clientId -d 'OAuth client ID' -r
|
|
389
|
+
complete -c c8ctl -l clientSecret -d 'OAuth client secret' -r
|
|
390
|
+
complete -c c8 -l clientSecret -d 'OAuth client secret' -r
|
|
391
|
+
complete -c c8ctl -l audience -d 'OAuth audience' -r
|
|
392
|
+
complete -c c8 -l audience -d 'OAuth audience' -r
|
|
393
|
+
complete -c c8ctl -l oAuthUrl -d 'OAuth token endpoint' -r
|
|
394
|
+
complete -c c8 -l oAuthUrl -d 'OAuth token endpoint' -r
|
|
395
|
+
complete -c c8ctl -l defaultTenantId -d 'Default tenant ID' -r
|
|
396
|
+
complete -c c8 -l defaultTenantId -d 'Default tenant ID' -r
|
|
397
|
+
complete -c c8ctl -l version_num -d 'Process definition version' -r
|
|
398
|
+
complete -c c8 -l version_num -d 'Process definition version' -r
|
|
399
|
+
|
|
400
|
+
# Commands (verbs) - only suggest when no command is given yet
|
|
401
|
+
complete -c c8ctl -n '__fish_use_subcommand' -a 'list' -d 'List resources'
|
|
402
|
+
complete -c c8 -n '__fish_use_subcommand' -a 'list' -d 'List resources'
|
|
403
|
+
complete -c c8ctl -n '__fish_use_subcommand' -a 'get' -d 'Get resource by key'
|
|
404
|
+
complete -c c8 -n '__fish_use_subcommand' -a 'get' -d 'Get resource by key'
|
|
405
|
+
complete -c c8ctl -n '__fish_use_subcommand' -a 'create' -d 'Create resource'
|
|
406
|
+
complete -c c8 -n '__fish_use_subcommand' -a 'create' -d 'Create resource'
|
|
407
|
+
complete -c c8ctl -n '__fish_use_subcommand' -a 'cancel' -d 'Cancel resource'
|
|
408
|
+
complete -c c8 -n '__fish_use_subcommand' -a 'cancel' -d 'Cancel resource'
|
|
409
|
+
complete -c c8ctl -n '__fish_use_subcommand' -a 'complete' -d 'Complete resource'
|
|
410
|
+
complete -c c8 -n '__fish_use_subcommand' -a 'complete' -d 'Complete resource'
|
|
411
|
+
complete -c c8ctl -n '__fish_use_subcommand' -a 'fail' -d 'Fail a job'
|
|
412
|
+
complete -c c8 -n '__fish_use_subcommand' -a 'fail' -d 'Fail a job'
|
|
413
|
+
complete -c c8ctl -n '__fish_use_subcommand' -a 'activate' -d 'Activate jobs by type'
|
|
414
|
+
complete -c c8 -n '__fish_use_subcommand' -a 'activate' -d 'Activate jobs by type'
|
|
415
|
+
complete -c c8ctl -n '__fish_use_subcommand' -a 'resolve' -d 'Resolve incident'
|
|
416
|
+
complete -c c8 -n '__fish_use_subcommand' -a 'resolve' -d 'Resolve incident'
|
|
417
|
+
complete -c c8ctl -n '__fish_use_subcommand' -a 'publish' -d 'Publish message'
|
|
418
|
+
complete -c c8 -n '__fish_use_subcommand' -a 'publish' -d 'Publish message'
|
|
419
|
+
complete -c c8ctl -n '__fish_use_subcommand' -a 'correlate' -d 'Correlate message'
|
|
420
|
+
complete -c c8 -n '__fish_use_subcommand' -a 'correlate' -d 'Correlate message'
|
|
421
|
+
complete -c c8ctl -n '__fish_use_subcommand' -a 'deploy' -d 'Deploy BPMN/DMN/forms'
|
|
422
|
+
complete -c c8 -n '__fish_use_subcommand' -a 'deploy' -d 'Deploy BPMN/DMN/forms'
|
|
423
|
+
complete -c c8ctl -n '__fish_use_subcommand' -a 'run' -d 'Deploy and start process'
|
|
424
|
+
complete -c c8 -n '__fish_use_subcommand' -a 'run' -d 'Deploy and start process'
|
|
425
|
+
complete -c c8ctl -n '__fish_use_subcommand' -a 'watch' -d 'Watch files and auto-deploy'
|
|
426
|
+
complete -c c8 -n '__fish_use_subcommand' -a 'watch' -d 'Watch files and auto-deploy'
|
|
427
|
+
complete -c c8ctl -n '__fish_use_subcommand' -a 'add' -d 'Add a profile'
|
|
428
|
+
complete -c c8 -n '__fish_use_subcommand' -a 'add' -d 'Add a profile'
|
|
429
|
+
complete -c c8ctl -n '__fish_use_subcommand' -a 'remove' -d 'Remove a profile'
|
|
430
|
+
complete -c c8 -n '__fish_use_subcommand' -a 'remove' -d 'Remove a profile'
|
|
431
|
+
complete -c c8ctl -n '__fish_use_subcommand' -a 'rm' -d 'Remove a profile'
|
|
432
|
+
complete -c c8 -n '__fish_use_subcommand' -a 'rm' -d 'Remove a profile'
|
|
433
|
+
complete -c c8ctl -n '__fish_use_subcommand' -a 'load' -d 'Load a c8ctl plugin'
|
|
434
|
+
complete -c c8 -n '__fish_use_subcommand' -a 'load' -d 'Load a c8ctl plugin'
|
|
435
|
+
complete -c c8ctl -n '__fish_use_subcommand' -a 'unload' -d 'Unload a c8ctl plugin'
|
|
436
|
+
complete -c c8 -n '__fish_use_subcommand' -a 'unload' -d 'Unload a c8ctl plugin'
|
|
437
|
+
complete -c c8ctl -n '__fish_use_subcommand' -a 'use' -d 'Set active profile or tenant'
|
|
438
|
+
complete -c c8 -n '__fish_use_subcommand' -a 'use' -d 'Set active profile or tenant'
|
|
439
|
+
complete -c c8ctl -n '__fish_use_subcommand' -a 'output' -d 'Set output format'
|
|
440
|
+
complete -c c8 -n '__fish_use_subcommand' -a 'output' -d 'Set output format'
|
|
441
|
+
complete -c c8ctl -n '__fish_use_subcommand' -a 'help' -d 'Show help'
|
|
442
|
+
complete -c c8 -n '__fish_use_subcommand' -a 'help' -d 'Show help'
|
|
443
|
+
complete -c c8ctl -n '__fish_use_subcommand' -a 'completion' -d 'Generate shell completion script'
|
|
444
|
+
complete -c c8 -n '__fish_use_subcommand' -a 'completion' -d 'Generate shell completion script'
|
|
445
|
+
|
|
446
|
+
# Resources for 'list' command
|
|
447
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from list' -a 'process-instances' -d 'List process instances'
|
|
448
|
+
complete -c c8 -n '__fish_seen_subcommand_from list' -a 'process-instances' -d 'List process instances'
|
|
449
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from list' -a 'process-instance' -d 'List process instances'
|
|
450
|
+
complete -c c8 -n '__fish_seen_subcommand_from list' -a 'process-instance' -d 'List process instances'
|
|
451
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from list' -a 'pi' -d 'List process instances'
|
|
452
|
+
complete -c c8 -n '__fish_seen_subcommand_from list' -a 'pi' -d 'List process instances'
|
|
453
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from list' -a 'user-tasks' -d 'List user tasks'
|
|
454
|
+
complete -c c8 -n '__fish_seen_subcommand_from list' -a 'user-tasks' -d 'List user tasks'
|
|
455
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from list' -a 'user-task' -d 'List user tasks'
|
|
456
|
+
complete -c c8 -n '__fish_seen_subcommand_from list' -a 'user-task' -d 'List user tasks'
|
|
457
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from list' -a 'ut' -d 'List user tasks'
|
|
458
|
+
complete -c c8 -n '__fish_seen_subcommand_from list' -a 'ut' -d 'List user tasks'
|
|
459
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from list' -a 'incidents' -d 'List incidents'
|
|
460
|
+
complete -c c8 -n '__fish_seen_subcommand_from list' -a 'incidents' -d 'List incidents'
|
|
461
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from list' -a 'incident' -d 'List incidents'
|
|
462
|
+
complete -c c8 -n '__fish_seen_subcommand_from list' -a 'incident' -d 'List incidents'
|
|
463
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from list' -a 'inc' -d 'List incidents'
|
|
464
|
+
complete -c c8 -n '__fish_seen_subcommand_from list' -a 'inc' -d 'List incidents'
|
|
465
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from list' -a 'jobs' -d 'List jobs'
|
|
466
|
+
complete -c c8 -n '__fish_seen_subcommand_from list' -a 'jobs' -d 'List jobs'
|
|
467
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from list' -a 'profiles' -d 'List profiles'
|
|
468
|
+
complete -c c8 -n '__fish_seen_subcommand_from list' -a 'profiles' -d 'List profiles'
|
|
469
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from list' -a 'profile' -d 'List profiles'
|
|
470
|
+
complete -c c8 -n '__fish_seen_subcommand_from list' -a 'profile' -d 'List profiles'
|
|
471
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from list' -a 'plugins' -d 'List plugins'
|
|
472
|
+
complete -c c8 -n '__fish_seen_subcommand_from list' -a 'plugins' -d 'List plugins'
|
|
473
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from list' -a 'plugin' -d 'List plugins'
|
|
474
|
+
complete -c c8 -n '__fish_seen_subcommand_from list' -a 'plugin' -d 'List plugins'
|
|
475
|
+
|
|
476
|
+
# Resources for 'get' command
|
|
477
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from get' -a 'process-instance' -d 'Get process instance'
|
|
478
|
+
complete -c c8 -n '__fish_seen_subcommand_from get' -a 'process-instance' -d 'Get process instance'
|
|
479
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from get' -a 'pi' -d 'Get process instance'
|
|
480
|
+
complete -c c8 -n '__fish_seen_subcommand_from get' -a 'pi' -d 'Get process instance'
|
|
481
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from get' -a 'topology' -d 'Get cluster topology'
|
|
482
|
+
complete -c c8 -n '__fish_seen_subcommand_from get' -a 'topology' -d 'Get cluster topology'
|
|
483
|
+
|
|
484
|
+
# Resources for 'create' command
|
|
485
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from create' -a 'process-instance' -d 'Create process instance'
|
|
486
|
+
complete -c c8 -n '__fish_seen_subcommand_from create' -a 'process-instance' -d 'Create process instance'
|
|
487
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from create' -a 'pi' -d 'Create process instance'
|
|
488
|
+
complete -c c8 -n '__fish_seen_subcommand_from create' -a 'pi' -d 'Create process instance'
|
|
489
|
+
|
|
490
|
+
# Resources for 'cancel' command
|
|
491
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from cancel' -a 'process-instance' -d 'Cancel process instance'
|
|
492
|
+
complete -c c8 -n '__fish_seen_subcommand_from cancel' -a 'process-instance' -d 'Cancel process instance'
|
|
493
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from cancel' -a 'pi' -d 'Cancel process instance'
|
|
494
|
+
complete -c c8 -n '__fish_seen_subcommand_from cancel' -a 'pi' -d 'Cancel process instance'
|
|
495
|
+
|
|
496
|
+
# Resources for 'complete' command
|
|
497
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from complete' -a 'user-task' -d 'Complete user task'
|
|
498
|
+
complete -c c8 -n '__fish_seen_subcommand_from complete' -a 'user-task' -d 'Complete user task'
|
|
499
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from complete' -a 'ut' -d 'Complete user task'
|
|
500
|
+
complete -c c8 -n '__fish_seen_subcommand_from complete' -a 'ut' -d 'Complete user task'
|
|
501
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from complete' -a 'job' -d 'Complete job'
|
|
502
|
+
complete -c c8 -n '__fish_seen_subcommand_from complete' -a 'job' -d 'Complete job'
|
|
503
|
+
|
|
504
|
+
# Resources for 'fail' command
|
|
505
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from fail' -a 'job' -d 'Fail job'
|
|
506
|
+
complete -c c8 -n '__fish_seen_subcommand_from fail' -a 'job' -d 'Fail job'
|
|
507
|
+
|
|
508
|
+
# Resources for 'activate' command
|
|
509
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from activate' -a 'jobs' -d 'Activate jobs'
|
|
510
|
+
complete -c c8 -n '__fish_seen_subcommand_from activate' -a 'jobs' -d 'Activate jobs'
|
|
511
|
+
|
|
512
|
+
# Resources for 'resolve' command
|
|
513
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from resolve' -a 'incident' -d 'Resolve incident'
|
|
514
|
+
complete -c c8 -n '__fish_seen_subcommand_from resolve' -a 'incident' -d 'Resolve incident'
|
|
515
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from resolve' -a 'inc' -d 'Resolve incident'
|
|
516
|
+
complete -c c8 -n '__fish_seen_subcommand_from resolve' -a 'inc' -d 'Resolve incident'
|
|
517
|
+
|
|
518
|
+
# Resources for 'publish' command
|
|
519
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from publish' -a 'message' -d 'Publish message'
|
|
520
|
+
complete -c c8 -n '__fish_seen_subcommand_from publish' -a 'message' -d 'Publish message'
|
|
521
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from publish' -a 'msg' -d 'Publish message'
|
|
522
|
+
complete -c c8 -n '__fish_seen_subcommand_from publish' -a 'msg' -d 'Publish message'
|
|
523
|
+
|
|
524
|
+
# Resources for 'correlate' command
|
|
525
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from correlate' -a 'message' -d 'Correlate message'
|
|
526
|
+
complete -c c8 -n '__fish_seen_subcommand_from correlate' -a 'message' -d 'Correlate message'
|
|
527
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from correlate' -a 'msg' -d 'Correlate message'
|
|
528
|
+
complete -c c8 -n '__fish_seen_subcommand_from correlate' -a 'msg' -d 'Correlate message'
|
|
529
|
+
|
|
530
|
+
# Resources for 'add' command
|
|
531
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from add' -a 'profile' -d 'Add profile'
|
|
532
|
+
complete -c c8 -n '__fish_seen_subcommand_from add' -a 'profile' -d 'Add profile'
|
|
533
|
+
|
|
534
|
+
# Resources for 'remove' and 'rm' commands
|
|
535
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from remove' -a 'profile' -d 'Remove profile'
|
|
536
|
+
complete -c c8 -n '__fish_seen_subcommand_from remove' -a 'profile' -d 'Remove profile'
|
|
537
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from rm' -a 'profile' -d 'Remove profile'
|
|
538
|
+
complete -c c8 -n '__fish_seen_subcommand_from rm' -a 'profile' -d 'Remove profile'
|
|
539
|
+
|
|
540
|
+
# Resources for 'load' command
|
|
541
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from load' -a 'plugin' -d 'Load plugin'
|
|
542
|
+
complete -c c8 -n '__fish_seen_subcommand_from load' -a 'plugin' -d 'Load plugin'
|
|
543
|
+
|
|
544
|
+
# Resources for 'unload' command
|
|
545
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from unload' -a 'plugin' -d 'Unload plugin'
|
|
546
|
+
complete -c c8 -n '__fish_seen_subcommand_from unload' -a 'plugin' -d 'Unload plugin'
|
|
547
|
+
|
|
548
|
+
# Resources for 'use' command
|
|
549
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from use' -a 'profile' -d 'Set active profile'
|
|
550
|
+
complete -c c8 -n '__fish_seen_subcommand_from use' -a 'profile' -d 'Set active profile'
|
|
551
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from use' -a 'tenant' -d 'Set active tenant'
|
|
552
|
+
complete -c c8 -n '__fish_seen_subcommand_from use' -a 'tenant' -d 'Set active tenant'
|
|
553
|
+
|
|
554
|
+
# Resources for 'output' command
|
|
555
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from output' -a 'json' -d 'JSON output'
|
|
556
|
+
complete -c c8 -n '__fish_seen_subcommand_from output' -a 'json' -d 'JSON output'
|
|
557
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from output' -a 'text' -d 'Text output'
|
|
558
|
+
complete -c c8 -n '__fish_seen_subcommand_from output' -a 'text' -d 'Text output'
|
|
559
|
+
|
|
560
|
+
# Resources for 'completion' command
|
|
561
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from completion' -a 'bash' -d 'Generate bash completion'
|
|
562
|
+
complete -c c8 -n '__fish_seen_subcommand_from completion' -a 'bash' -d 'Generate bash completion'
|
|
563
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from completion' -a 'zsh' -d 'Generate zsh completion'
|
|
564
|
+
complete -c c8 -n '__fish_seen_subcommand_from completion' -a 'zsh' -d 'Generate zsh completion'
|
|
565
|
+
complete -c c8ctl -n '__fish_seen_subcommand_from completion' -a 'fish' -d 'Generate fish completion'
|
|
566
|
+
complete -c c8 -n '__fish_seen_subcommand_from completion' -a 'fish' -d 'Generate fish completion'
|
|
567
|
+
`;
|
|
568
|
+
}
|
|
569
|
+
/**
|
|
570
|
+
* Show completion command
|
|
571
|
+
*/
|
|
572
|
+
export function showCompletion(shell) {
|
|
573
|
+
const logger = getLogger();
|
|
574
|
+
if (!shell) {
|
|
575
|
+
logger.error('Shell type required. Usage: c8 completion <bash|zsh|fish>');
|
|
576
|
+
process.exit(1);
|
|
577
|
+
}
|
|
578
|
+
const normalizedShell = shell.toLowerCase();
|
|
579
|
+
switch (normalizedShell) {
|
|
580
|
+
case 'bash':
|
|
581
|
+
console.log(generateBashCompletion());
|
|
582
|
+
break;
|
|
583
|
+
case 'zsh':
|
|
584
|
+
console.log(generateZshCompletion());
|
|
585
|
+
break;
|
|
586
|
+
case 'fish':
|
|
587
|
+
console.log(generateFishCompletion());
|
|
588
|
+
break;
|
|
589
|
+
default:
|
|
590
|
+
logger.error(`Unknown shell: ${shell}`);
|
|
591
|
+
logger.info('Supported shells: bash, zsh, fish');
|
|
592
|
+
logger.info('Usage: c8 completion <bash|zsh|fish>');
|
|
593
|
+
process.exit(1);
|
|
594
|
+
}
|
|
595
|
+
}
|
|
596
|
+
//# sourceMappingURL=completion.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"completion.js","sourceRoot":"","sources":["../../src/commands/completion.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAEzC;;GAEG;AACH,SAAS,sBAAsB;IAC7B,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAmHR,CAAC;AACF,CAAC;AAED;;GAEG;AACH,SAAS,qBAAqB;IAC5B,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA8MR,CAAC;AACF,CAAC;AAED;;GAEG;AACH,SAAS,sBAAsB;IAC7B,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAiOR,CAAC;AACF,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,cAAc,CAAC,KAAc;IAC3C,MAAM,MAAM,GAAG,SAAS,EAAE,CAAC;IAE3B,IAAI,CAAC,KAAK,EAAE,CAAC;QACX,MAAM,CAAC,KAAK,CAAC,2DAA2D,CAAC,CAAC;QAC1E,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IAClB,CAAC;IAED,MAAM,eAAe,GAAG,KAAK,CAAC,WAAW,EAAE,CAAC;IAE5C,QAAQ,eAAe,EAAE,CAAC;QACxB,KAAK,MAAM;YACT,OAAO,CAAC,GAAG,CAAC,sBAAsB,EAAE,CAAC,CAAC;YACtC,MAAM;QACR,KAAK,KAAK;YACR,OAAO,CAAC,GAAG,CAAC,qBAAqB,EAAE,CAAC,CAAC;YACrC,MAAM;QACR,KAAK,MAAM;YACT,OAAO,CAAC,GAAG,CAAC,sBAAsB,EAAE,CAAC,CAAC;YACtC,MAAM;QACR;YACE,MAAM,CAAC,KAAK,CAAC,kBAAkB,KAAK,EAAE,CAAC,CAAC;YACxC,MAAM,CAAC,IAAI,CAAC,mCAAmC,CAAC,CAAC;YACjD,MAAM,CAAC,IAAI,CAAC,sCAAsC,CAAC,CAAC;YACpD,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IACpB,CAAC;AACH,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"help.d.ts","sourceRoot":"","sources":["../../src/commands/help.ts"],"names":[],"mappings":"AAAA;;GAEG;AAWH;;GAEG;AACH,wBAAgB,UAAU,IAAI,MAAM,CAInC;AAED;;GAEG;AACH,wBAAgB,WAAW,IAAI,IAAI,CAGlC;AAED;;GAEG;AACH,wBAAgB,QAAQ,IAAI,IAAI,
|
|
1
|
+
{"version":3,"file":"help.d.ts","sourceRoot":"","sources":["../../src/commands/help.ts"],"names":[],"mappings":"AAAA;;GAEG;AAWH;;GAEG;AACH,wBAAgB,UAAU,IAAI,MAAM,CAInC;AAED;;GAEG;AACH,wBAAgB,WAAW,IAAI,IAAI,CAGlC;AAED;;GAEG;AACH,wBAAgB,QAAQ,IAAI,IAAI,CAwE/B;AAED;;GAEG;AACH,wBAAgB,iBAAiB,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,CA8BpD"}
|
package/dist/commands/help.js
CHANGED
|
@@ -43,8 +43,8 @@ c8ctl - Camunda 8 CLI v${version}
|
|
|
43
43
|
Usage: c8ctl <command> [resource] [options]
|
|
44
44
|
|
|
45
45
|
Commands:
|
|
46
|
-
list <resource> List resources (pi, ut, inc, jobs, profiles)
|
|
47
|
-
get <resource> <key> Get resource by key (pi, topology)
|
|
46
|
+
list <resource> List resources (pi, pd, ut, inc, jobs, profiles)
|
|
47
|
+
get <resource> <key> Get resource by key (pi, pd, topology)
|
|
48
48
|
create <resource> Create resource (pi)
|
|
49
49
|
cancel <resource> <key> Cancel resource (pi)
|
|
50
50
|
complete <resource> <key> Complete resource (ut, job)
|
|
@@ -63,23 +63,29 @@ Commands:
|
|
|
63
63
|
unload plugin <name> Unload a c8ctl plugin (npm uninstall wrapper)
|
|
64
64
|
use profile|tenant Set active profile or tenant
|
|
65
65
|
output json|text Set output format
|
|
66
|
+
completion bash|zsh|fish Generate shell completion script
|
|
66
67
|
help Show this help${pluginSection}
|
|
67
68
|
|
|
68
69
|
Flags:
|
|
69
70
|
--profile <name> Use specific profile for this command
|
|
70
71
|
--from <url> Load plugin from URL (use with 'load plugin')
|
|
72
|
+
--xml Get process definition as XML (use with 'get pd')
|
|
71
73
|
--version, -v Show version
|
|
72
74
|
--help, -h Show help
|
|
73
75
|
|
|
74
76
|
Resource Aliases:
|
|
75
77
|
pi = process-instance(s)
|
|
78
|
+
pd = process-definition(s)
|
|
76
79
|
ut = user-task(s)
|
|
77
80
|
inc = incident(s)
|
|
78
81
|
msg = message
|
|
79
82
|
|
|
80
83
|
Examples:
|
|
81
84
|
c8ctl list pi List process instances
|
|
85
|
+
c8ctl list pd List process definitions
|
|
82
86
|
c8ctl get pi 123456 Get process instance by key
|
|
87
|
+
c8ctl get pd 123456 Get process definition by key
|
|
88
|
+
c8ctl get pd 123456 --xml Get process definition XML
|
|
83
89
|
c8ctl create pi --bpmnProcessId=myProcess
|
|
84
90
|
c8ctl deploy ./my-process.bpmn Deploy a BPMN file
|
|
85
91
|
c8ctl run ./my-process.bpmn Deploy and start process
|
|
@@ -88,6 +94,7 @@ Examples:
|
|
|
88
94
|
c8ctl output json Switch to JSON output
|
|
89
95
|
c8ctl load plugin my-plugin Load plugin from npm registry
|
|
90
96
|
c8ctl load plugin --from file:///path/to/plugin Load plugin from file URL
|
|
97
|
+
c8ctl completion bash Generate bash completion script
|
|
91
98
|
`.trim());
|
|
92
99
|
}
|
|
93
100
|
/**
|
|
@@ -95,8 +102,8 @@ Examples:
|
|
|
95
102
|
*/
|
|
96
103
|
export function showVerbResources(verb) {
|
|
97
104
|
const resources = {
|
|
98
|
-
list: 'process-instances (pi), user-tasks (ut), incidents (inc), jobs, profiles, plugins',
|
|
99
|
-
get: 'process-instance (pi), topology',
|
|
105
|
+
list: 'process-instances (pi), process-definitions (pd), user-tasks (ut), incidents (inc), jobs, profiles, plugins',
|
|
106
|
+
get: 'process-instance (pi), process-definition (pd), topology',
|
|
100
107
|
create: 'process-instance (pi)',
|
|
101
108
|
complete: 'user-task (ut), job',
|
|
102
109
|
cancel: 'process-instance (pi)',
|
|
@@ -112,6 +119,7 @@ export function showVerbResources(verb) {
|
|
|
112
119
|
unload: 'plugin',
|
|
113
120
|
use: 'profile, tenant',
|
|
114
121
|
output: 'json, text',
|
|
122
|
+
completion: 'bash, zsh, fish',
|
|
115
123
|
};
|
|
116
124
|
const available = resources[verb];
|
|
117
125
|
if (available) {
|