@reventlessdev/rescript-node 2.0.0-alpha.2 → 2.0.0-alpha.4
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/CHANGELOG.md +15 -0
- package/package.json +1 -1
- package/src/NodeChildProcess.res +29 -0
- package/src/NodeModule.res +5 -0
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,21 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
# 2.0.0-alpha.4 (2026-08-11)
|
|
7
|
+
|
|
8
|
+
**Note:** Version bump only for package @reventlessdev/rescript-node
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
# 2.0.0-alpha.3 (2026-08-09)
|
|
15
|
+
|
|
16
|
+
### Features
|
|
17
|
+
|
|
18
|
+
* **core,aws:** bundle a runtime extension's companion packages, guard imports at deploy ([e975175](https://github.com/ReventlessDev/reventless-core/commit/e9751758f51582a8e46db362219f725bb5f1bcde))
|
|
19
|
+
|
|
20
|
+
|
|
6
21
|
# 2.0.0-alpha.2 (2026-08-05)
|
|
7
22
|
|
|
8
23
|
### Features
|
package/package.json
CHANGED
package/src/NodeChildProcess.res
CHANGED
|
@@ -16,3 +16,32 @@ external execSync: (string, execOptions) => string = "execSync"
|
|
|
16
16
|
string, so an argument containing shell metacharacters stays one argument. */
|
|
17
17
|
@module("node:child_process")
|
|
18
18
|
external execFileSync: (string, array<string>, execOptions) => string = "execFileSync"
|
|
19
|
+
|
|
20
|
+
/** A running child process. Unlike the `*Sync` calls above, `spawn` returns
|
|
21
|
+
while the child is still alive, so the caller keeps working alongside it —
|
|
22
|
+
which is the whole reason to reach for this over `execFileSync`. */
|
|
23
|
+
type childProcess
|
|
24
|
+
|
|
25
|
+
type spawnOptions = {
|
|
26
|
+
cwd?: string,
|
|
27
|
+
/** Replaces the child's environment entirely rather than extending it. Pass
|
|
28
|
+
a copy of `NodeProcess.env` with the additions applied when the child
|
|
29
|
+
still needs PATH and friends. */
|
|
30
|
+
env?: dict<string>,
|
|
31
|
+
/** Per-descriptor disposition: `"ignore"`, `"inherit"`, or `"pipe"`, in
|
|
32
|
+
stdin/stdout/stderr order. */
|
|
33
|
+
stdio?: array<string>,
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
@module("node:child_process")
|
|
37
|
+
external spawn: (string, array<string>, spawnOptions) => childProcess = "spawn"
|
|
38
|
+
|
|
39
|
+
/** `null` while the child is running, its exit code once it has exited. The
|
|
40
|
+
one honest way to ask "is it still alive?" without holding an event
|
|
41
|
+
listener — a caller polling for readiness checks this to tell a slow start
|
|
42
|
+
from a process that already died. */
|
|
43
|
+
@get external exitCode: childProcess => Nullable.t<int> = "exitCode"
|
|
44
|
+
|
|
45
|
+
/** Signal the child. Returns whether the signal was delivered — `false` once
|
|
46
|
+
the process is already gone, which is not an error. */
|
|
47
|
+
@send external kill: (childProcess, string) => bool = "kill"
|
package/src/NodeModule.res
CHANGED
|
@@ -10,3 +10,8 @@ type require
|
|
|
10
10
|
external createRequire: string => require = "createRequire"
|
|
11
11
|
|
|
12
12
|
@send external requireResolve: (require, string) => string = "resolve"
|
|
13
|
+
|
|
14
|
+
/** The names of Node's built-in modules (both bare and some `node:`-only
|
|
15
|
+
entries like `node:test`), plus subpath forms such as `fs/promises`. */
|
|
16
|
+
@module("node:module")
|
|
17
|
+
external builtinModules: array<string> = "builtinModules"
|