@plurnk/plurnk-execs-common 1.9.2 → 1.10.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/docs/node.md +6 -4
- package/docs/sh.md +15 -16
- package/package.json +44 -30
package/docs/node.md
CHANGED
|
@@ -16,7 +16,9 @@ on stderr.
|
|
|
16
16
|
|
|
17
17
|
## Working directory
|
|
18
18
|
|
|
19
|
-
Runs in the workspace project root by default.
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
19
|
+
Runs in the workspace project root by default — `(.)` names it explicitly, or
|
|
20
|
+
the daemon's own cwd in a workspace without one. The target is a cwd or a
|
|
21
|
+
script, never a command: a directory target sets the working directory; a
|
|
22
|
+
script target runs that JavaScript file and receives the body as stdin; anything
|
|
23
|
+
else is refused before anything runs. Relative module and filesystem paths
|
|
24
|
+
resolve against the selected working directory. The receipt always names it.
|
package/docs/sh.md
CHANGED
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
# sh
|
|
2
2
|
|
|
3
|
-
A shell command line, run via `sh -c
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
whitespace.
|
|
3
|
+
A bare `EXEC` is the shell. The body is the command line, run via `sh -c`,
|
|
4
|
+
character-perfect including whitespace. `[sh]` and `[bash]` name the shell
|
|
5
|
+
explicitly — `## EXEC0 [bash] (.)` runs the body under bash.
|
|
7
6
|
|
|
8
7
|
## Environment
|
|
9
8
|
|
|
@@ -13,25 +12,25 @@ read plurnk's credentials. The project's environment passes through.
|
|
|
13
12
|
|
|
14
13
|
## Working directory
|
|
15
14
|
|
|
16
|
-
|
|
15
|
+
`(.)` is the workspace project root — where file operations write — or, in a
|
|
16
|
+
workspace without one, the directory the shell would run in anyway. Any
|
|
17
|
+
directory target becomes the working directory for its body:
|
|
17
18
|
|
|
18
19
|
```plurnk
|
|
19
|
-
## EXEC0
|
|
20
|
+
## EXEC0 (./dir)
|
|
20
21
|
pwd
|
|
21
22
|
```
|
|
22
23
|
|
|
23
|
-
With no target, the command runs in
|
|
24
|
-
|
|
24
|
+
With no target, the command runs in that same directory. The receipt always
|
|
25
|
+
names the directory the command ran in.
|
|
25
26
|
|
|
26
|
-
|
|
27
|
+
A script target runs that script: `## EXEC0 (greet.sh)` runs it with an empty
|
|
28
|
+
stdin; a nonempty body becomes its stdin. The interpreter reads the script
|
|
29
|
+
directly, so it needs no executable bit; a script path authored inside a shell
|
|
30
|
+
body still follows the kernel's ordinary executable-bit rules.
|
|
27
31
|
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
empty stdin; a nonempty body becomes stdin.
|
|
31
|
-
|
|
32
|
-
The interpreter reads a targeted file directly, so it needs no executable bit.
|
|
33
|
-
A script path authored inside a shell body still follows the kernel's ordinary
|
|
34
|
-
executable-bit rules.
|
|
32
|
+
The target is a cwd or a script — never a command. A target that is neither is
|
|
33
|
+
refused before anything runs, and the refusal names the directory it searched.
|
|
35
34
|
|
|
36
35
|
## Channels
|
|
37
36
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@plurnk/plurnk-execs-common",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.10.1",
|
|
4
4
|
"description": "Universal subprocess executor for plurnk-service's exec scheme — one package exposing the shell + node + python floor plus whichever host interpreters (perl, ruby, php, lua, awk, bc, …) are present.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"plurnk",
|
|
@@ -40,16 +40,17 @@
|
|
|
40
40
|
"summary": "Run POSIX shell commands and scripts.",
|
|
41
41
|
"invocation": {
|
|
42
42
|
"body": {
|
|
43
|
-
"role": "shell program; stdin
|
|
43
|
+
"role": "the shell program; stdin when the target is a script",
|
|
44
44
|
"required": false
|
|
45
45
|
},
|
|
46
46
|
"target": {
|
|
47
|
-
"role": "script
|
|
47
|
+
"role": "cwd or script; never a command",
|
|
48
48
|
"required": false,
|
|
49
49
|
"kind": "resource",
|
|
50
50
|
"directory": "cwd"
|
|
51
51
|
},
|
|
52
52
|
"example": {
|
|
53
|
+
"target": ".",
|
|
53
54
|
"body": "pwd"
|
|
54
55
|
}
|
|
55
56
|
}
|
|
@@ -60,16 +61,17 @@
|
|
|
60
61
|
"summary": "Run Bash commands and scripts.",
|
|
61
62
|
"invocation": {
|
|
62
63
|
"body": {
|
|
63
|
-
"role": "Bash program; stdin
|
|
64
|
+
"role": "the Bash program; stdin when the target is a script",
|
|
64
65
|
"required": false
|
|
65
66
|
},
|
|
66
67
|
"target": {
|
|
67
|
-
"role": "script
|
|
68
|
+
"role": "cwd or script; never a command",
|
|
68
69
|
"required": false,
|
|
69
70
|
"kind": "resource",
|
|
70
71
|
"directory": "cwd"
|
|
71
72
|
},
|
|
72
73
|
"example": {
|
|
74
|
+
"target": ".",
|
|
73
75
|
"body": "npm test"
|
|
74
76
|
}
|
|
75
77
|
}
|
|
@@ -80,16 +82,17 @@
|
|
|
80
82
|
"summary": "Run JavaScript programs with Node.js.",
|
|
81
83
|
"invocation": {
|
|
82
84
|
"body": {
|
|
83
|
-
"role": "JavaScript program; stdin
|
|
85
|
+
"role": "JavaScript program; stdin when the target is a script",
|
|
84
86
|
"required": false
|
|
85
87
|
},
|
|
86
88
|
"target": {
|
|
87
|
-
"role": "script
|
|
89
|
+
"role": "cwd or script; never a command",
|
|
88
90
|
"required": false,
|
|
89
91
|
"kind": "resource",
|
|
90
92
|
"directory": "cwd"
|
|
91
93
|
},
|
|
92
94
|
"example": {
|
|
95
|
+
"target": ".",
|
|
93
96
|
"body": "console.log(process.version);"
|
|
94
97
|
}
|
|
95
98
|
}
|
|
@@ -100,16 +103,17 @@
|
|
|
100
103
|
"summary": "Run Python programs.",
|
|
101
104
|
"invocation": {
|
|
102
105
|
"body": {
|
|
103
|
-
"role": "Python program; stdin
|
|
106
|
+
"role": "Python program; stdin when the target is a script",
|
|
104
107
|
"required": false
|
|
105
108
|
},
|
|
106
109
|
"target": {
|
|
107
|
-
"role": "script
|
|
110
|
+
"role": "cwd or script; never a command",
|
|
108
111
|
"required": false,
|
|
109
112
|
"kind": "resource",
|
|
110
113
|
"directory": "cwd"
|
|
111
114
|
},
|
|
112
115
|
"example": {
|
|
116
|
+
"target": ".",
|
|
113
117
|
"body": "print(\"hello\")"
|
|
114
118
|
}
|
|
115
119
|
}
|
|
@@ -120,16 +124,17 @@
|
|
|
120
124
|
"summary": "Run Python 3 programs.",
|
|
121
125
|
"invocation": {
|
|
122
126
|
"body": {
|
|
123
|
-
"role": "Python program; stdin
|
|
127
|
+
"role": "Python program; stdin when the target is a script",
|
|
124
128
|
"required": false
|
|
125
129
|
},
|
|
126
130
|
"target": {
|
|
127
|
-
"role": "script
|
|
131
|
+
"role": "cwd or script; never a command",
|
|
128
132
|
"required": false,
|
|
129
133
|
"kind": "resource",
|
|
130
134
|
"directory": "cwd"
|
|
131
135
|
},
|
|
132
136
|
"example": {
|
|
137
|
+
"target": ".",
|
|
133
138
|
"body": "print(\"hello\")"
|
|
134
139
|
}
|
|
135
140
|
}
|
|
@@ -140,16 +145,17 @@
|
|
|
140
145
|
"summary": "Run Perl programs.",
|
|
141
146
|
"invocation": {
|
|
142
147
|
"body": {
|
|
143
|
-
"role": "Perl program; stdin
|
|
148
|
+
"role": "Perl program; stdin when the target is a script",
|
|
144
149
|
"required": false
|
|
145
150
|
},
|
|
146
151
|
"target": {
|
|
147
|
-
"role": "script
|
|
152
|
+
"role": "cwd or script; never a command",
|
|
148
153
|
"required": false,
|
|
149
154
|
"kind": "resource",
|
|
150
155
|
"directory": "cwd"
|
|
151
156
|
},
|
|
152
157
|
"example": {
|
|
158
|
+
"target": ".",
|
|
153
159
|
"body": "print \"hello\\n\";"
|
|
154
160
|
}
|
|
155
161
|
}
|
|
@@ -160,16 +166,17 @@
|
|
|
160
166
|
"summary": "Run Ruby programs.",
|
|
161
167
|
"invocation": {
|
|
162
168
|
"body": {
|
|
163
|
-
"role": "Ruby program; stdin
|
|
169
|
+
"role": "Ruby program; stdin when the target is a script",
|
|
164
170
|
"required": false
|
|
165
171
|
},
|
|
166
172
|
"target": {
|
|
167
|
-
"role": "script
|
|
173
|
+
"role": "cwd or script; never a command",
|
|
168
174
|
"required": false,
|
|
169
175
|
"kind": "resource",
|
|
170
176
|
"directory": "cwd"
|
|
171
177
|
},
|
|
172
178
|
"example": {
|
|
179
|
+
"target": ".",
|
|
173
180
|
"body": "puts \"hello\""
|
|
174
181
|
}
|
|
175
182
|
}
|
|
@@ -180,16 +187,17 @@
|
|
|
180
187
|
"summary": "Run PHP programs.",
|
|
181
188
|
"invocation": {
|
|
182
189
|
"body": {
|
|
183
|
-
"role": "PHP program; stdin
|
|
190
|
+
"role": "PHP program; stdin when the target is a script",
|
|
184
191
|
"required": false
|
|
185
192
|
},
|
|
186
193
|
"target": {
|
|
187
|
-
"role": "script
|
|
194
|
+
"role": "cwd or script; never a command",
|
|
188
195
|
"required": false,
|
|
189
196
|
"kind": "resource",
|
|
190
197
|
"directory": "cwd"
|
|
191
198
|
},
|
|
192
199
|
"example": {
|
|
200
|
+
"target": ".",
|
|
193
201
|
"body": "<?php echo \"hello\\n\";"
|
|
194
202
|
}
|
|
195
203
|
}
|
|
@@ -200,16 +208,17 @@
|
|
|
200
208
|
"summary": "Run Lua programs.",
|
|
201
209
|
"invocation": {
|
|
202
210
|
"body": {
|
|
203
|
-
"role": "Lua program; stdin
|
|
211
|
+
"role": "Lua program; stdin when the target is a script",
|
|
204
212
|
"required": false
|
|
205
213
|
},
|
|
206
214
|
"target": {
|
|
207
|
-
"role": "script
|
|
215
|
+
"role": "cwd or script; never a command",
|
|
208
216
|
"required": false,
|
|
209
217
|
"kind": "resource",
|
|
210
218
|
"directory": "cwd"
|
|
211
219
|
},
|
|
212
220
|
"example": {
|
|
221
|
+
"target": ".",
|
|
213
222
|
"body": "print(\"hello\")"
|
|
214
223
|
}
|
|
215
224
|
}
|
|
@@ -220,16 +229,17 @@
|
|
|
220
229
|
"summary": "Run TypeScript or JavaScript programs with Deno.",
|
|
221
230
|
"invocation": {
|
|
222
231
|
"body": {
|
|
223
|
-
"role": "Deno program; stdin
|
|
232
|
+
"role": "Deno program; stdin when the target is a script",
|
|
224
233
|
"required": false
|
|
225
234
|
},
|
|
226
235
|
"target": {
|
|
227
|
-
"role": "script
|
|
236
|
+
"role": "cwd or script; never a command",
|
|
228
237
|
"required": false,
|
|
229
238
|
"kind": "resource",
|
|
230
239
|
"directory": "cwd"
|
|
231
240
|
},
|
|
232
241
|
"example": {
|
|
242
|
+
"target": ".",
|
|
233
243
|
"body": "console.log(Deno.version.deno);"
|
|
234
244
|
}
|
|
235
245
|
}
|
|
@@ -240,16 +250,17 @@
|
|
|
240
250
|
"summary": "Run TypeScript or JavaScript programs with Bun.",
|
|
241
251
|
"invocation": {
|
|
242
252
|
"body": {
|
|
243
|
-
"role": "Bun program; stdin
|
|
253
|
+
"role": "Bun program; stdin when the target is a script",
|
|
244
254
|
"required": false
|
|
245
255
|
},
|
|
246
256
|
"target": {
|
|
247
|
-
"role": "script
|
|
257
|
+
"role": "cwd or script; never a command",
|
|
248
258
|
"required": false,
|
|
249
259
|
"kind": "resource",
|
|
250
260
|
"directory": "cwd"
|
|
251
261
|
},
|
|
252
262
|
"example": {
|
|
263
|
+
"target": ".",
|
|
253
264
|
"body": "console.log(Bun.version);"
|
|
254
265
|
}
|
|
255
266
|
}
|
|
@@ -260,16 +271,17 @@
|
|
|
260
271
|
"summary": "Run Tcl programs.",
|
|
261
272
|
"invocation": {
|
|
262
273
|
"body": {
|
|
263
|
-
"role": "Tcl program; stdin
|
|
274
|
+
"role": "Tcl program; stdin when the target is a script",
|
|
264
275
|
"required": false
|
|
265
276
|
},
|
|
266
277
|
"target": {
|
|
267
|
-
"role": "script
|
|
278
|
+
"role": "cwd or script; never a command",
|
|
268
279
|
"required": false,
|
|
269
280
|
"kind": "resource",
|
|
270
281
|
"directory": "cwd"
|
|
271
282
|
},
|
|
272
283
|
"example": {
|
|
284
|
+
"target": ".",
|
|
273
285
|
"body": "puts \"hello\""
|
|
274
286
|
}
|
|
275
287
|
}
|
|
@@ -280,16 +292,17 @@
|
|
|
280
292
|
"summary": "Evaluate calculations with bc.",
|
|
281
293
|
"invocation": {
|
|
282
294
|
"body": {
|
|
283
|
-
"role": "bc program; stdin
|
|
295
|
+
"role": "bc program; stdin when the target is a script",
|
|
284
296
|
"required": false
|
|
285
297
|
},
|
|
286
298
|
"target": {
|
|
287
|
-
"role": "script
|
|
299
|
+
"role": "cwd or script; never a command",
|
|
288
300
|
"required": false,
|
|
289
301
|
"kind": "resource",
|
|
290
302
|
"directory": "cwd"
|
|
291
303
|
},
|
|
292
304
|
"example": {
|
|
305
|
+
"target": ".",
|
|
293
306
|
"body": "2 + 2"
|
|
294
307
|
}
|
|
295
308
|
}
|
|
@@ -300,16 +313,17 @@
|
|
|
300
313
|
"summary": "Run AWK programs.",
|
|
301
314
|
"invocation": {
|
|
302
315
|
"body": {
|
|
303
|
-
"role": "AWK program; stdin
|
|
316
|
+
"role": "AWK program; stdin when the target is a script",
|
|
304
317
|
"required": false
|
|
305
318
|
},
|
|
306
319
|
"target": {
|
|
307
|
-
"role": "script
|
|
320
|
+
"role": "cwd or script; never a command",
|
|
308
321
|
"required": false,
|
|
309
322
|
"kind": "resource",
|
|
310
323
|
"directory": "cwd"
|
|
311
324
|
},
|
|
312
325
|
"example": {
|
|
326
|
+
"target": ".",
|
|
313
327
|
"body": "BEGIN { print \"hello\" }"
|
|
314
328
|
}
|
|
315
329
|
}
|
|
@@ -341,6 +355,6 @@
|
|
|
341
355
|
"prepublishOnly": "npm audit --audit-level=moderate && npm test"
|
|
342
356
|
},
|
|
343
357
|
"peerDependencies": {
|
|
344
|
-
"@plurnk/plurnk-execs": "^1.
|
|
358
|
+
"@plurnk/plurnk-execs": "^1.10.1"
|
|
345
359
|
}
|
|
346
360
|
}
|