@opencode-cockpit/protocol 0.1.5 → 0.2.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/dist/index.js +2 -2
- package/dist/rpc.js +1 -1
- package/dist/shell/common.js +13 -0
- package/dist/shell/contract.js +55 -0
- package/dist/shell/index.js +6 -0
- package/dist/shell/info.js +33 -0
- package/dist/{shell.js → shell/params.js} +26 -75
- package/dist/shell/watch.js +37 -0
- package/package.json +3 -3
- package/types/index.d.ts +292 -1
- package/types/rpc.d.ts +1 -1
- package/types/shell/common.d.ts +16 -0
- package/types/{shell.d.ts → shell/contract.d.ts} +306 -241
- package/types/shell/index.d.ts +6 -0
- package/types/shell/info.d.ts +48 -0
- package/types/shell/params.d.ts +215 -0
- package/types/shell/watch.d.ts +46 -0
|
@@ -1,221 +1,6 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
|
-
export declare const ShellId: z.ZodString;
|
|
3
|
-
export declare const Owner: z.ZodObject<{
|
|
4
|
-
project: z.ZodString;
|
|
5
|
-
session: z.ZodOptional<z.ZodString>;
|
|
6
|
-
instance: z.ZodOptional<z.ZodString>;
|
|
7
|
-
}, z.core.$strip>;
|
|
8
|
-
export declare const ShellStatus: z.ZodEnum<{
|
|
9
|
-
exited: "exited";
|
|
10
|
-
failed: "failed";
|
|
11
|
-
killed: "killed";
|
|
12
|
-
running: "running";
|
|
13
|
-
}>;
|
|
14
|
-
export declare const ShellInfo: z.ZodObject<{
|
|
15
|
-
id: z.ZodString;
|
|
16
|
-
title: z.ZodString;
|
|
17
|
-
command: z.ZodString;
|
|
18
|
-
args: z.ZodArray<z.ZodString>;
|
|
19
|
-
cwd: z.ZodString;
|
|
20
|
-
owner: z.ZodObject<{
|
|
21
|
-
project: z.ZodString;
|
|
22
|
-
session: z.ZodOptional<z.ZodString>;
|
|
23
|
-
instance: z.ZodOptional<z.ZodString>;
|
|
24
|
-
}, z.core.$strip>;
|
|
25
|
-
status: z.ZodEnum<{
|
|
26
|
-
exited: "exited";
|
|
27
|
-
failed: "failed";
|
|
28
|
-
killed: "killed";
|
|
29
|
-
running: "running";
|
|
30
|
-
}>;
|
|
31
|
-
run: z.ZodNumber;
|
|
32
|
-
pid: z.ZodOptional<z.ZodNumber>;
|
|
33
|
-
exitCode: z.ZodOptional<z.ZodNumber>;
|
|
34
|
-
signal: z.ZodOptional<z.ZodString>;
|
|
35
|
-
error: z.ZodOptional<z.ZodString>;
|
|
36
|
-
summary: z.ZodOptional<z.ZodString>;
|
|
37
|
-
startedAt: z.ZodNumber;
|
|
38
|
-
endedAt: z.ZodOptional<z.ZodNumber>;
|
|
39
|
-
cols: z.ZodNumber;
|
|
40
|
-
rows: z.ZodNumber;
|
|
41
|
-
lines: z.ZodObject<{
|
|
42
|
-
first: z.ZodNumber;
|
|
43
|
-
last: z.ZodNumber;
|
|
44
|
-
}, z.core.$strip>;
|
|
45
|
-
bytes: z.ZodNumber;
|
|
46
|
-
}, z.core.$strip>;
|
|
47
|
-
export declare const StartParams: z.ZodObject<{
|
|
48
|
-
command: z.ZodString;
|
|
49
|
-
args: z.ZodDefault<z.ZodArray<z.ZodString>>;
|
|
50
|
-
cwd: z.ZodString;
|
|
51
|
-
env: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
52
|
-
title: z.ZodOptional<z.ZodString>;
|
|
53
|
-
cols: z.ZodDefault<z.ZodNumber>;
|
|
54
|
-
rows: z.ZodDefault<z.ZodNumber>;
|
|
55
|
-
owner: z.ZodObject<{
|
|
56
|
-
project: z.ZodString;
|
|
57
|
-
session: z.ZodOptional<z.ZodString>;
|
|
58
|
-
instance: z.ZodOptional<z.ZodString>;
|
|
59
|
-
}, z.core.$strip>;
|
|
60
|
-
timeoutMs: z.ZodOptional<z.ZodNumber>;
|
|
61
|
-
reuse: z.ZodDefault<z.ZodBoolean>;
|
|
62
|
-
}, z.core.$strip>;
|
|
63
|
-
export declare const ClearParams: z.ZodDefault<z.ZodObject<{
|
|
64
|
-
owner: z.ZodOptional<z.ZodObject<{
|
|
65
|
-
project: z.ZodOptional<z.ZodString>;
|
|
66
|
-
session: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
67
|
-
instance: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
68
|
-
}, z.core.$strip>>;
|
|
69
|
-
finishedBeforeMs: z.ZodOptional<z.ZodNumber>;
|
|
70
|
-
}, z.core.$strip>>;
|
|
71
|
-
export declare const ListParams: z.ZodDefault<z.ZodObject<{
|
|
72
|
-
owner: z.ZodOptional<z.ZodObject<{
|
|
73
|
-
project: z.ZodOptional<z.ZodString>;
|
|
74
|
-
session: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
75
|
-
instance: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
76
|
-
}, z.core.$strip>>;
|
|
77
|
-
includeExited: z.ZodDefault<z.ZodBoolean>;
|
|
78
|
-
}, z.core.$strip>>;
|
|
79
|
-
export declare const IdParams: z.ZodObject<{
|
|
80
|
-
id: z.ZodString;
|
|
81
|
-
}, z.core.$strip>;
|
|
82
|
-
export declare const LogLine: z.ZodObject<{
|
|
83
|
-
n: z.ZodNumber;
|
|
84
|
-
text: z.ZodString;
|
|
85
|
-
}, z.core.$strip>;
|
|
86
|
-
export declare const ReadParams: z.ZodObject<{
|
|
87
|
-
id: z.ZodString;
|
|
88
|
-
after: z.ZodOptional<z.ZodNumber>;
|
|
89
|
-
tail: z.ZodDefault<z.ZodNumber>;
|
|
90
|
-
limit: z.ZodDefault<z.ZodNumber>;
|
|
91
|
-
grep: z.ZodOptional<z.ZodString>;
|
|
92
|
-
ignoreCase: z.ZodDefault<z.ZodBoolean>;
|
|
93
|
-
}, z.core.$strip>;
|
|
94
|
-
export declare const ReadResult: z.ZodObject<{
|
|
95
|
-
lines: z.ZodArray<z.ZodObject<{
|
|
96
|
-
n: z.ZodNumber;
|
|
97
|
-
text: z.ZodString;
|
|
98
|
-
}, z.core.$strip>>;
|
|
99
|
-
firstLine: z.ZodNumber;
|
|
100
|
-
lastLine: z.ZodNumber;
|
|
101
|
-
nextCursor: z.ZodNumber;
|
|
102
|
-
truncated: z.ZodBoolean;
|
|
103
|
-
hasMore: z.ZodBoolean;
|
|
104
|
-
status: z.ZodEnum<{
|
|
105
|
-
exited: "exited";
|
|
106
|
-
failed: "failed";
|
|
107
|
-
killed: "killed";
|
|
108
|
-
running: "running";
|
|
109
|
-
}>;
|
|
110
|
-
}, z.core.$strip>;
|
|
111
|
-
export declare const ScreenResult: z.ZodObject<{
|
|
112
|
-
text: z.ZodString;
|
|
113
|
-
cols: z.ZodNumber;
|
|
114
|
-
rows: z.ZodNumber;
|
|
115
|
-
cursor: z.ZodObject<{
|
|
116
|
-
x: z.ZodNumber;
|
|
117
|
-
y: z.ZodNumber;
|
|
118
|
-
}, z.core.$strip>;
|
|
119
|
-
}, z.core.$strip>;
|
|
120
|
-
export declare const WriteParams: z.ZodObject<{
|
|
121
|
-
id: z.ZodString;
|
|
122
|
-
data: z.ZodString;
|
|
123
|
-
}, z.core.$strip>;
|
|
124
|
-
export declare const ResizeParams: z.ZodObject<{
|
|
125
|
-
id: z.ZodString;
|
|
126
|
-
cols: z.ZodNumber;
|
|
127
|
-
rows: z.ZodNumber;
|
|
128
|
-
}, z.core.$strip>;
|
|
129
|
-
export declare const WaitUntil: z.ZodObject<{
|
|
130
|
-
pattern: z.ZodOptional<z.ZodString>;
|
|
131
|
-
ignoreCase: z.ZodOptional<z.ZodBoolean>;
|
|
132
|
-
exit: z.ZodOptional<z.ZodBoolean>;
|
|
133
|
-
idleMs: z.ZodOptional<z.ZodNumber>;
|
|
134
|
-
port: z.ZodOptional<z.ZodNumber>;
|
|
135
|
-
host: z.ZodOptional<z.ZodString>;
|
|
136
|
-
}, z.core.$strip>;
|
|
137
|
-
export declare const WaitParams: z.ZodObject<{
|
|
138
|
-
id: z.ZodString;
|
|
139
|
-
until: z.ZodObject<{
|
|
140
|
-
pattern: z.ZodOptional<z.ZodString>;
|
|
141
|
-
ignoreCase: z.ZodOptional<z.ZodBoolean>;
|
|
142
|
-
exit: z.ZodOptional<z.ZodBoolean>;
|
|
143
|
-
idleMs: z.ZodOptional<z.ZodNumber>;
|
|
144
|
-
port: z.ZodOptional<z.ZodNumber>;
|
|
145
|
-
host: z.ZodOptional<z.ZodString>;
|
|
146
|
-
}, z.core.$strip>;
|
|
147
|
-
timeoutMs: z.ZodNumber;
|
|
148
|
-
after: z.ZodOptional<z.ZodNumber>;
|
|
149
|
-
}, z.core.$strip>;
|
|
150
|
-
export declare const WaitReason: z.ZodEnum<{
|
|
151
|
-
exit: "exit";
|
|
152
|
-
idle: "idle";
|
|
153
|
-
pattern: "pattern";
|
|
154
|
-
port: "port";
|
|
155
|
-
timeout: "timeout";
|
|
156
|
-
}>;
|
|
157
|
-
export declare const WaitResult: z.ZodObject<{
|
|
158
|
-
reason: z.ZodEnum<{
|
|
159
|
-
exit: "exit";
|
|
160
|
-
idle: "idle";
|
|
161
|
-
pattern: "pattern";
|
|
162
|
-
port: "port";
|
|
163
|
-
timeout: "timeout";
|
|
164
|
-
}>;
|
|
165
|
-
match: z.ZodOptional<z.ZodObject<{
|
|
166
|
-
n: z.ZodNumber;
|
|
167
|
-
text: z.ZodString;
|
|
168
|
-
}, z.core.$strip>>;
|
|
169
|
-
info: z.ZodObject<{
|
|
170
|
-
id: z.ZodString;
|
|
171
|
-
title: z.ZodString;
|
|
172
|
-
command: z.ZodString;
|
|
173
|
-
args: z.ZodArray<z.ZodString>;
|
|
174
|
-
cwd: z.ZodString;
|
|
175
|
-
owner: z.ZodObject<{
|
|
176
|
-
project: z.ZodString;
|
|
177
|
-
session: z.ZodOptional<z.ZodString>;
|
|
178
|
-
instance: z.ZodOptional<z.ZodString>;
|
|
179
|
-
}, z.core.$strip>;
|
|
180
|
-
status: z.ZodEnum<{
|
|
181
|
-
exited: "exited";
|
|
182
|
-
failed: "failed";
|
|
183
|
-
killed: "killed";
|
|
184
|
-
running: "running";
|
|
185
|
-
}>;
|
|
186
|
-
run: z.ZodNumber;
|
|
187
|
-
pid: z.ZodOptional<z.ZodNumber>;
|
|
188
|
-
exitCode: z.ZodOptional<z.ZodNumber>;
|
|
189
|
-
signal: z.ZodOptional<z.ZodString>;
|
|
190
|
-
error: z.ZodOptional<z.ZodString>;
|
|
191
|
-
summary: z.ZodOptional<z.ZodString>;
|
|
192
|
-
startedAt: z.ZodNumber;
|
|
193
|
-
endedAt: z.ZodOptional<z.ZodNumber>;
|
|
194
|
-
cols: z.ZodNumber;
|
|
195
|
-
rows: z.ZodNumber;
|
|
196
|
-
lines: z.ZodObject<{
|
|
197
|
-
first: z.ZodNumber;
|
|
198
|
-
last: z.ZodNumber;
|
|
199
|
-
}, z.core.$strip>;
|
|
200
|
-
bytes: z.ZodNumber;
|
|
201
|
-
}, z.core.$strip>;
|
|
202
|
-
}, z.core.$strip>;
|
|
203
|
-
export declare const StopParams: z.ZodObject<{
|
|
204
|
-
id: z.ZodString;
|
|
205
|
-
signal: z.ZodDefault<z.ZodEnum<{
|
|
206
|
-
SIGHUP: "SIGHUP";
|
|
207
|
-
SIGINT: "SIGINT";
|
|
208
|
-
SIGKILL: "SIGKILL";
|
|
209
|
-
SIGTERM: "SIGTERM";
|
|
210
|
-
}>>;
|
|
211
|
-
graceMs: z.ZodDefault<z.ZodNumber>;
|
|
212
|
-
}, z.core.$strip>;
|
|
213
|
-
export declare const AttachParams: z.ZodObject<{
|
|
214
|
-
id: z.ZodString;
|
|
215
|
-
fromOffset: z.ZodOptional<z.ZodNumber>;
|
|
216
|
-
}, z.core.$strip>;
|
|
217
2
|
export declare const shellContract: {
|
|
218
|
-
"shell.start": import("
|
|
3
|
+
"shell.start": import("../contract.ts").MethodSpec<z.ZodObject<{
|
|
219
4
|
command: z.ZodString;
|
|
220
5
|
args: z.ZodDefault<z.ZodArray<z.ZodString>>;
|
|
221
6
|
cwd: z.ZodString;
|
|
@@ -229,6 +14,8 @@ export declare const shellContract: {
|
|
|
229
14
|
instance: z.ZodOptional<z.ZodString>;
|
|
230
15
|
}, z.core.$strip>;
|
|
231
16
|
timeoutMs: z.ZodOptional<z.ZodNumber>;
|
|
17
|
+
idleTimeoutMs: z.ZodOptional<z.ZodNumber>;
|
|
18
|
+
logFile: z.ZodDefault<z.ZodBoolean>;
|
|
232
19
|
reuse: z.ZodDefault<z.ZodBoolean>;
|
|
233
20
|
}, z.core.$strip>, z.ZodObject<{
|
|
234
21
|
id: z.ZodString;
|
|
@@ -262,8 +49,21 @@ export declare const shellContract: {
|
|
|
262
49
|
last: z.ZodNumber;
|
|
263
50
|
}, z.core.$strip>;
|
|
264
51
|
bytes: z.ZodNumber;
|
|
52
|
+
watch: z.ZodOptional<z.ZodObject<{
|
|
53
|
+
preset: z.ZodOptional<z.ZodString>;
|
|
54
|
+
status: z.ZodEnum<{
|
|
55
|
+
fail: "fail";
|
|
56
|
+
ok: "ok";
|
|
57
|
+
pending: "pending";
|
|
58
|
+
unknown: "unknown";
|
|
59
|
+
}>;
|
|
60
|
+
summary: z.ZodOptional<z.ZodString>;
|
|
61
|
+
runs: z.ZodNumber;
|
|
62
|
+
since: z.ZodNumber;
|
|
63
|
+
}, z.core.$strip>>;
|
|
64
|
+
logFile: z.ZodOptional<z.ZodString>;
|
|
265
65
|
}, z.core.$strip>>;
|
|
266
|
-
"shell.list": import("
|
|
66
|
+
"shell.list": import("../contract.ts").MethodSpec<z.ZodDefault<z.ZodObject<{
|
|
267
67
|
owner: z.ZodOptional<z.ZodObject<{
|
|
268
68
|
project: z.ZodOptional<z.ZodString>;
|
|
269
69
|
session: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
@@ -302,8 +102,21 @@ export declare const shellContract: {
|
|
|
302
102
|
last: z.ZodNumber;
|
|
303
103
|
}, z.core.$strip>;
|
|
304
104
|
bytes: z.ZodNumber;
|
|
105
|
+
watch: z.ZodOptional<z.ZodObject<{
|
|
106
|
+
preset: z.ZodOptional<z.ZodString>;
|
|
107
|
+
status: z.ZodEnum<{
|
|
108
|
+
fail: "fail";
|
|
109
|
+
ok: "ok";
|
|
110
|
+
pending: "pending";
|
|
111
|
+
unknown: "unknown";
|
|
112
|
+
}>;
|
|
113
|
+
summary: z.ZodOptional<z.ZodString>;
|
|
114
|
+
runs: z.ZodNumber;
|
|
115
|
+
since: z.ZodNumber;
|
|
116
|
+
}, z.core.$strip>>;
|
|
117
|
+
logFile: z.ZodOptional<z.ZodString>;
|
|
305
118
|
}, z.core.$strip>>>;
|
|
306
|
-
"shell.get": import("
|
|
119
|
+
"shell.get": import("../contract.ts").MethodSpec<z.ZodObject<{
|
|
307
120
|
id: z.ZodString;
|
|
308
121
|
}, z.core.$strip>, z.ZodObject<{
|
|
309
122
|
id: z.ZodString;
|
|
@@ -337,8 +150,21 @@ export declare const shellContract: {
|
|
|
337
150
|
last: z.ZodNumber;
|
|
338
151
|
}, z.core.$strip>;
|
|
339
152
|
bytes: z.ZodNumber;
|
|
153
|
+
watch: z.ZodOptional<z.ZodObject<{
|
|
154
|
+
preset: z.ZodOptional<z.ZodString>;
|
|
155
|
+
status: z.ZodEnum<{
|
|
156
|
+
fail: "fail";
|
|
157
|
+
ok: "ok";
|
|
158
|
+
pending: "pending";
|
|
159
|
+
unknown: "unknown";
|
|
160
|
+
}>;
|
|
161
|
+
summary: z.ZodOptional<z.ZodString>;
|
|
162
|
+
runs: z.ZodNumber;
|
|
163
|
+
since: z.ZodNumber;
|
|
164
|
+
}, z.core.$strip>>;
|
|
165
|
+
logFile: z.ZodOptional<z.ZodString>;
|
|
340
166
|
}, z.core.$strip>>;
|
|
341
|
-
"shell.read": import("
|
|
167
|
+
"shell.read": import("../contract.ts").MethodSpec<z.ZodObject<{
|
|
342
168
|
id: z.ZodString;
|
|
343
169
|
after: z.ZodOptional<z.ZodNumber>;
|
|
344
170
|
tail: z.ZodDefault<z.ZodNumber>;
|
|
@@ -362,7 +188,7 @@ export declare const shellContract: {
|
|
|
362
188
|
running: "running";
|
|
363
189
|
}>;
|
|
364
190
|
}, z.core.$strip>>;
|
|
365
|
-
"shell.screen": import("
|
|
191
|
+
"shell.screen": import("../contract.ts").MethodSpec<z.ZodObject<{
|
|
366
192
|
id: z.ZodString;
|
|
367
193
|
}, z.core.$strip>, z.ZodObject<{
|
|
368
194
|
text: z.ZodString;
|
|
@@ -372,19 +198,28 @@ export declare const shellContract: {
|
|
|
372
198
|
x: z.ZodNumber;
|
|
373
199
|
y: z.ZodNumber;
|
|
374
200
|
}, z.core.$strip>;
|
|
201
|
+
styled: z.ZodOptional<z.ZodArray<z.ZodArray<z.ZodObject<{
|
|
202
|
+
text: z.ZodString;
|
|
203
|
+
fg: z.ZodOptional<z.ZodString>;
|
|
204
|
+
bg: z.ZodOptional<z.ZodString>;
|
|
205
|
+
bold: z.ZodOptional<z.ZodBoolean>;
|
|
206
|
+
dim: z.ZodOptional<z.ZodBoolean>;
|
|
207
|
+
italic: z.ZodOptional<z.ZodBoolean>;
|
|
208
|
+
underline: z.ZodOptional<z.ZodBoolean>;
|
|
209
|
+
}, z.core.$strip>>>>;
|
|
375
210
|
}, z.core.$strip>>;
|
|
376
|
-
"shell.write": import("
|
|
211
|
+
"shell.write": import("../contract.ts").MethodSpec<z.ZodObject<{
|
|
377
212
|
id: z.ZodString;
|
|
378
213
|
data: z.ZodString;
|
|
379
214
|
}, z.core.$strip>, z.ZodObject<{
|
|
380
215
|
bytes: z.ZodNumber;
|
|
381
216
|
}, z.core.$strip>>;
|
|
382
|
-
"shell.resize": import("
|
|
217
|
+
"shell.resize": import("../contract.ts").MethodSpec<z.ZodObject<{
|
|
383
218
|
id: z.ZodString;
|
|
384
219
|
cols: z.ZodNumber;
|
|
385
220
|
rows: z.ZodNumber;
|
|
386
221
|
}, z.core.$strip>, z.ZodObject<{}, z.core.$strip>>;
|
|
387
|
-
"shell.wait": import("
|
|
222
|
+
"shell.wait": import("../contract.ts").MethodSpec<z.ZodObject<{
|
|
388
223
|
id: z.ZodString;
|
|
389
224
|
until: z.ZodObject<{
|
|
390
225
|
pattern: z.ZodOptional<z.ZodString>;
|
|
@@ -440,9 +275,22 @@ export declare const shellContract: {
|
|
|
440
275
|
last: z.ZodNumber;
|
|
441
276
|
}, z.core.$strip>;
|
|
442
277
|
bytes: z.ZodNumber;
|
|
278
|
+
watch: z.ZodOptional<z.ZodObject<{
|
|
279
|
+
preset: z.ZodOptional<z.ZodString>;
|
|
280
|
+
status: z.ZodEnum<{
|
|
281
|
+
fail: "fail";
|
|
282
|
+
ok: "ok";
|
|
283
|
+
pending: "pending";
|
|
284
|
+
unknown: "unknown";
|
|
285
|
+
}>;
|
|
286
|
+
summary: z.ZodOptional<z.ZodString>;
|
|
287
|
+
runs: z.ZodNumber;
|
|
288
|
+
since: z.ZodNumber;
|
|
289
|
+
}, z.core.$strip>>;
|
|
290
|
+
logFile: z.ZodOptional<z.ZodString>;
|
|
443
291
|
}, z.core.$strip>;
|
|
444
292
|
}, z.core.$strip>>;
|
|
445
|
-
"shell.stop": import("
|
|
293
|
+
"shell.stop": import("../contract.ts").MethodSpec<z.ZodObject<{
|
|
446
294
|
id: z.ZodString;
|
|
447
295
|
signal: z.ZodDefault<z.ZodEnum<{
|
|
448
296
|
SIGHUP: "SIGHUP";
|
|
@@ -483,8 +331,21 @@ export declare const shellContract: {
|
|
|
483
331
|
last: z.ZodNumber;
|
|
484
332
|
}, z.core.$strip>;
|
|
485
333
|
bytes: z.ZodNumber;
|
|
334
|
+
watch: z.ZodOptional<z.ZodObject<{
|
|
335
|
+
preset: z.ZodOptional<z.ZodString>;
|
|
336
|
+
status: z.ZodEnum<{
|
|
337
|
+
fail: "fail";
|
|
338
|
+
ok: "ok";
|
|
339
|
+
pending: "pending";
|
|
340
|
+
unknown: "unknown";
|
|
341
|
+
}>;
|
|
342
|
+
summary: z.ZodOptional<z.ZodString>;
|
|
343
|
+
runs: z.ZodNumber;
|
|
344
|
+
since: z.ZodNumber;
|
|
345
|
+
}, z.core.$strip>>;
|
|
346
|
+
logFile: z.ZodOptional<z.ZodString>;
|
|
486
347
|
}, z.core.$strip>>;
|
|
487
|
-
"shell.restart": import("
|
|
348
|
+
"shell.restart": import("../contract.ts").MethodSpec<z.ZodObject<{
|
|
488
349
|
id: z.ZodString;
|
|
489
350
|
}, z.core.$strip>, z.ZodObject<{
|
|
490
351
|
id: z.ZodString;
|
|
@@ -518,11 +379,24 @@ export declare const shellContract: {
|
|
|
518
379
|
last: z.ZodNumber;
|
|
519
380
|
}, z.core.$strip>;
|
|
520
381
|
bytes: z.ZodNumber;
|
|
382
|
+
watch: z.ZodOptional<z.ZodObject<{
|
|
383
|
+
preset: z.ZodOptional<z.ZodString>;
|
|
384
|
+
status: z.ZodEnum<{
|
|
385
|
+
fail: "fail";
|
|
386
|
+
ok: "ok";
|
|
387
|
+
pending: "pending";
|
|
388
|
+
unknown: "unknown";
|
|
389
|
+
}>;
|
|
390
|
+
summary: z.ZodOptional<z.ZodString>;
|
|
391
|
+
runs: z.ZodNumber;
|
|
392
|
+
since: z.ZodNumber;
|
|
393
|
+
}, z.core.$strip>>;
|
|
394
|
+
logFile: z.ZodOptional<z.ZodString>;
|
|
521
395
|
}, z.core.$strip>>;
|
|
522
|
-
"shell.remove": import("
|
|
396
|
+
"shell.remove": import("../contract.ts").MethodSpec<z.ZodObject<{
|
|
523
397
|
id: z.ZodString;
|
|
524
398
|
}, z.core.$strip>, z.ZodObject<{}, z.core.$strip>>;
|
|
525
|
-
"shell.clear": import("
|
|
399
|
+
"shell.clear": import("../contract.ts").MethodSpec<z.ZodDefault<z.ZodObject<{
|
|
526
400
|
owner: z.ZodOptional<z.ZodObject<{
|
|
527
401
|
project: z.ZodOptional<z.ZodString>;
|
|
528
402
|
session: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
@@ -532,14 +406,129 @@ export declare const shellContract: {
|
|
|
532
406
|
}, z.core.$strip>>, z.ZodObject<{
|
|
533
407
|
removed: z.ZodArray<z.ZodString>;
|
|
534
408
|
}, z.core.$strip>>;
|
|
535
|
-
"shell.
|
|
409
|
+
"shell.watch": import("../contract.ts").MethodSpec<z.ZodObject<{
|
|
410
|
+
id: z.ZodString;
|
|
411
|
+
preset: z.ZodOptional<z.ZodString>;
|
|
412
|
+
rule: z.ZodOptional<z.ZodObject<{
|
|
413
|
+
done: z.ZodOptional<z.ZodString>;
|
|
414
|
+
fail: z.ZodOptional<z.ZodString>;
|
|
415
|
+
ok: z.ZodOptional<z.ZodString>;
|
|
416
|
+
ignoreCase: z.ZodOptional<z.ZodBoolean>;
|
|
417
|
+
idleSeconds: z.ZodOptional<z.ZodNumber>;
|
|
418
|
+
}, z.core.$strip>>;
|
|
419
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
420
|
+
id: z.ZodString;
|
|
421
|
+
title: z.ZodString;
|
|
422
|
+
command: z.ZodString;
|
|
423
|
+
args: z.ZodArray<z.ZodString>;
|
|
424
|
+
cwd: z.ZodString;
|
|
425
|
+
owner: z.ZodObject<{
|
|
426
|
+
project: z.ZodString;
|
|
427
|
+
session: z.ZodOptional<z.ZodString>;
|
|
428
|
+
instance: z.ZodOptional<z.ZodString>;
|
|
429
|
+
}, z.core.$strip>;
|
|
430
|
+
status: z.ZodEnum<{
|
|
431
|
+
exited: "exited";
|
|
432
|
+
failed: "failed";
|
|
433
|
+
killed: "killed";
|
|
434
|
+
running: "running";
|
|
435
|
+
}>;
|
|
436
|
+
run: z.ZodNumber;
|
|
437
|
+
pid: z.ZodOptional<z.ZodNumber>;
|
|
438
|
+
exitCode: z.ZodOptional<z.ZodNumber>;
|
|
439
|
+
signal: z.ZodOptional<z.ZodString>;
|
|
440
|
+
error: z.ZodOptional<z.ZodString>;
|
|
441
|
+
summary: z.ZodOptional<z.ZodString>;
|
|
442
|
+
startedAt: z.ZodNumber;
|
|
443
|
+
endedAt: z.ZodOptional<z.ZodNumber>;
|
|
444
|
+
cols: z.ZodNumber;
|
|
445
|
+
rows: z.ZodNumber;
|
|
446
|
+
lines: z.ZodObject<{
|
|
447
|
+
first: z.ZodNumber;
|
|
448
|
+
last: z.ZodNumber;
|
|
449
|
+
}, z.core.$strip>;
|
|
450
|
+
bytes: z.ZodNumber;
|
|
451
|
+
watch: z.ZodOptional<z.ZodObject<{
|
|
452
|
+
preset: z.ZodOptional<z.ZodString>;
|
|
453
|
+
status: z.ZodEnum<{
|
|
454
|
+
fail: "fail";
|
|
455
|
+
ok: "ok";
|
|
456
|
+
pending: "pending";
|
|
457
|
+
unknown: "unknown";
|
|
458
|
+
}>;
|
|
459
|
+
summary: z.ZodOptional<z.ZodString>;
|
|
460
|
+
runs: z.ZodNumber;
|
|
461
|
+
since: z.ZodNumber;
|
|
462
|
+
}, z.core.$strip>>;
|
|
463
|
+
logFile: z.ZodOptional<z.ZodString>;
|
|
464
|
+
}, z.core.$strip>>;
|
|
465
|
+
"shell.unwatch": import("../contract.ts").MethodSpec<z.ZodObject<{
|
|
466
|
+
id: z.ZodString;
|
|
467
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
468
|
+
id: z.ZodString;
|
|
469
|
+
title: z.ZodString;
|
|
470
|
+
command: z.ZodString;
|
|
471
|
+
args: z.ZodArray<z.ZodString>;
|
|
472
|
+
cwd: z.ZodString;
|
|
473
|
+
owner: z.ZodObject<{
|
|
474
|
+
project: z.ZodString;
|
|
475
|
+
session: z.ZodOptional<z.ZodString>;
|
|
476
|
+
instance: z.ZodOptional<z.ZodString>;
|
|
477
|
+
}, z.core.$strip>;
|
|
478
|
+
status: z.ZodEnum<{
|
|
479
|
+
exited: "exited";
|
|
480
|
+
failed: "failed";
|
|
481
|
+
killed: "killed";
|
|
482
|
+
running: "running";
|
|
483
|
+
}>;
|
|
484
|
+
run: z.ZodNumber;
|
|
485
|
+
pid: z.ZodOptional<z.ZodNumber>;
|
|
486
|
+
exitCode: z.ZodOptional<z.ZodNumber>;
|
|
487
|
+
signal: z.ZodOptional<z.ZodString>;
|
|
488
|
+
error: z.ZodOptional<z.ZodString>;
|
|
489
|
+
summary: z.ZodOptional<z.ZodString>;
|
|
490
|
+
startedAt: z.ZodNumber;
|
|
491
|
+
endedAt: z.ZodOptional<z.ZodNumber>;
|
|
492
|
+
cols: z.ZodNumber;
|
|
493
|
+
rows: z.ZodNumber;
|
|
494
|
+
lines: z.ZodObject<{
|
|
495
|
+
first: z.ZodNumber;
|
|
496
|
+
last: z.ZodNumber;
|
|
497
|
+
}, z.core.$strip>;
|
|
498
|
+
bytes: z.ZodNumber;
|
|
499
|
+
watch: z.ZodOptional<z.ZodObject<{
|
|
500
|
+
preset: z.ZodOptional<z.ZodString>;
|
|
501
|
+
status: z.ZodEnum<{
|
|
502
|
+
fail: "fail";
|
|
503
|
+
ok: "ok";
|
|
504
|
+
pending: "pending";
|
|
505
|
+
unknown: "unknown";
|
|
506
|
+
}>;
|
|
507
|
+
summary: z.ZodOptional<z.ZodString>;
|
|
508
|
+
runs: z.ZodNumber;
|
|
509
|
+
since: z.ZodNumber;
|
|
510
|
+
}, z.core.$strip>>;
|
|
511
|
+
logFile: z.ZodOptional<z.ZodString>;
|
|
512
|
+
}, z.core.$strip>>;
|
|
513
|
+
"shell.presets": import("../contract.ts").MethodSpec<z.ZodOptional<z.ZodObject<{}, z.core.$strip>>, z.ZodArray<z.ZodObject<{
|
|
514
|
+
name: z.ZodString;
|
|
515
|
+
match: z.ZodOptional<z.ZodString>;
|
|
516
|
+
rule: z.ZodObject<{
|
|
517
|
+
done: z.ZodOptional<z.ZodString>;
|
|
518
|
+
fail: z.ZodOptional<z.ZodString>;
|
|
519
|
+
ok: z.ZodOptional<z.ZodString>;
|
|
520
|
+
ignoreCase: z.ZodOptional<z.ZodBoolean>;
|
|
521
|
+
idleSeconds: z.ZodOptional<z.ZodNumber>;
|
|
522
|
+
}, z.core.$strip>;
|
|
523
|
+
}, z.core.$strip>>>;
|
|
524
|
+
"shell.attach": import("../contract.ts").MethodSpec<z.ZodObject<{
|
|
536
525
|
id: z.ZodString;
|
|
537
526
|
fromOffset: z.ZodOptional<z.ZodNumber>;
|
|
538
527
|
}, z.core.$strip>, z.ZodObject<{
|
|
539
528
|
offset: z.ZodNumber;
|
|
540
529
|
replay: z.ZodString;
|
|
541
530
|
}, z.core.$strip>>;
|
|
542
|
-
"shell.detach": import("
|
|
531
|
+
"shell.detach": import("../contract.ts").MethodSpec<z.ZodObject<{
|
|
543
532
|
id: z.ZodString;
|
|
544
533
|
}, z.core.$strip>, z.ZodObject<{}, z.core.$strip>>;
|
|
545
534
|
};
|
|
@@ -576,6 +565,19 @@ export declare const shellEvents: {
|
|
|
576
565
|
last: z.ZodNumber;
|
|
577
566
|
}, z.core.$strip>;
|
|
578
567
|
bytes: z.ZodNumber;
|
|
568
|
+
watch: z.ZodOptional<z.ZodObject<{
|
|
569
|
+
preset: z.ZodOptional<z.ZodString>;
|
|
570
|
+
status: z.ZodEnum<{
|
|
571
|
+
fail: "fail";
|
|
572
|
+
ok: "ok";
|
|
573
|
+
pending: "pending";
|
|
574
|
+
unknown: "unknown";
|
|
575
|
+
}>;
|
|
576
|
+
summary: z.ZodOptional<z.ZodString>;
|
|
577
|
+
runs: z.ZodNumber;
|
|
578
|
+
since: z.ZodNumber;
|
|
579
|
+
}, z.core.$strip>>;
|
|
580
|
+
logFile: z.ZodOptional<z.ZodString>;
|
|
579
581
|
}, z.core.$strip>;
|
|
580
582
|
"shell.exited": z.ZodObject<{
|
|
581
583
|
id: z.ZodString;
|
|
@@ -609,6 +611,19 @@ export declare const shellEvents: {
|
|
|
609
611
|
last: z.ZodNumber;
|
|
610
612
|
}, z.core.$strip>;
|
|
611
613
|
bytes: z.ZodNumber;
|
|
614
|
+
watch: z.ZodOptional<z.ZodObject<{
|
|
615
|
+
preset: z.ZodOptional<z.ZodString>;
|
|
616
|
+
status: z.ZodEnum<{
|
|
617
|
+
fail: "fail";
|
|
618
|
+
ok: "ok";
|
|
619
|
+
pending: "pending";
|
|
620
|
+
unknown: "unknown";
|
|
621
|
+
}>;
|
|
622
|
+
summary: z.ZodOptional<z.ZodString>;
|
|
623
|
+
runs: z.ZodNumber;
|
|
624
|
+
since: z.ZodNumber;
|
|
625
|
+
}, z.core.$strip>>;
|
|
626
|
+
logFile: z.ZodOptional<z.ZodString>;
|
|
612
627
|
}, z.core.$strip>;
|
|
613
628
|
"shell.removed": z.ZodObject<{
|
|
614
629
|
id: z.ZodString;
|
|
@@ -618,16 +633,66 @@ export declare const shellEvents: {
|
|
|
618
633
|
offset: z.ZodNumber;
|
|
619
634
|
data: z.ZodString;
|
|
620
635
|
}, z.core.$strip>;
|
|
636
|
+
/** Emitted only when a watcher's status changes, never per line. */
|
|
637
|
+
"shell.watch": z.ZodObject<{
|
|
638
|
+
info: z.ZodObject<{
|
|
639
|
+
id: z.ZodString;
|
|
640
|
+
title: z.ZodString;
|
|
641
|
+
command: z.ZodString;
|
|
642
|
+
args: z.ZodArray<z.ZodString>;
|
|
643
|
+
cwd: z.ZodString;
|
|
644
|
+
owner: z.ZodObject<{
|
|
645
|
+
project: z.ZodString;
|
|
646
|
+
session: z.ZodOptional<z.ZodString>;
|
|
647
|
+
instance: z.ZodOptional<z.ZodString>;
|
|
648
|
+
}, z.core.$strip>;
|
|
649
|
+
status: z.ZodEnum<{
|
|
650
|
+
exited: "exited";
|
|
651
|
+
failed: "failed";
|
|
652
|
+
killed: "killed";
|
|
653
|
+
running: "running";
|
|
654
|
+
}>;
|
|
655
|
+
run: z.ZodNumber;
|
|
656
|
+
pid: z.ZodOptional<z.ZodNumber>;
|
|
657
|
+
exitCode: z.ZodOptional<z.ZodNumber>;
|
|
658
|
+
signal: z.ZodOptional<z.ZodString>;
|
|
659
|
+
error: z.ZodOptional<z.ZodString>;
|
|
660
|
+
summary: z.ZodOptional<z.ZodString>;
|
|
661
|
+
startedAt: z.ZodNumber;
|
|
662
|
+
endedAt: z.ZodOptional<z.ZodNumber>;
|
|
663
|
+
cols: z.ZodNumber;
|
|
664
|
+
rows: z.ZodNumber;
|
|
665
|
+
lines: z.ZodObject<{
|
|
666
|
+
first: z.ZodNumber;
|
|
667
|
+
last: z.ZodNumber;
|
|
668
|
+
}, z.core.$strip>;
|
|
669
|
+
bytes: z.ZodNumber;
|
|
670
|
+
watch: z.ZodOptional<z.ZodObject<{
|
|
671
|
+
preset: z.ZodOptional<z.ZodString>;
|
|
672
|
+
status: z.ZodEnum<{
|
|
673
|
+
fail: "fail";
|
|
674
|
+
ok: "ok";
|
|
675
|
+
pending: "pending";
|
|
676
|
+
unknown: "unknown";
|
|
677
|
+
}>;
|
|
678
|
+
summary: z.ZodOptional<z.ZodString>;
|
|
679
|
+
runs: z.ZodNumber;
|
|
680
|
+
since: z.ZodNumber;
|
|
681
|
+
}, z.core.$strip>>;
|
|
682
|
+
logFile: z.ZodOptional<z.ZodString>;
|
|
683
|
+
}, z.core.$strip>;
|
|
684
|
+
previous: z.ZodEnum<{
|
|
685
|
+
fail: "fail";
|
|
686
|
+
ok: "ok";
|
|
687
|
+
pending: "pending";
|
|
688
|
+
unknown: "unknown";
|
|
689
|
+
}>;
|
|
690
|
+
current: z.ZodEnum<{
|
|
691
|
+
fail: "fail";
|
|
692
|
+
ok: "ok";
|
|
693
|
+
pending: "pending";
|
|
694
|
+
unknown: "unknown";
|
|
695
|
+
}>;
|
|
696
|
+
summary: z.ZodOptional<z.ZodString>;
|
|
697
|
+
}, z.core.$strip>;
|
|
621
698
|
};
|
|
622
|
-
export type Owner = z.output<typeof Owner>;
|
|
623
|
-
export type ShellStatus = z.output<typeof ShellStatus>;
|
|
624
|
-
export type ShellInfo = z.output<typeof ShellInfo>;
|
|
625
|
-
export type StartParams = z.output<typeof StartParams>;
|
|
626
|
-
export type ReadParams = z.output<typeof ReadParams>;
|
|
627
|
-
export type ReadResult = z.output<typeof ReadResult>;
|
|
628
|
-
export type ScreenResult = z.output<typeof ScreenResult>;
|
|
629
|
-
export type WaitParams = z.output<typeof WaitParams>;
|
|
630
|
-
export type WaitResult = z.output<typeof WaitResult>;
|
|
631
|
-
export type WaitReason = z.output<typeof WaitReason>;
|
|
632
|
-
export type StopParams = z.output<typeof StopParams>;
|
|
633
|
-
export type LogLine = z.output<typeof LogLine>;
|