@jdxcode/aube-node-linux-arm64-musl 0.0.1-placeholder → 1.28.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/README.md +83 -2
- package/aube.node +0 -0
- package/package.json +17 -3
- package/index.js +0 -1
package/README.md
CHANGED
|
@@ -1,3 +1,84 @@
|
|
|
1
|
-
#
|
|
1
|
+
# aube Node-API bindings
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
`@jdxcode/aube-node` embeds aube's installer in JavaScript hosts, including
|
|
4
|
+
Node.js, Bun, Electron, and compiled Bun executables.
|
|
5
|
+
|
|
6
|
+
```ts
|
|
7
|
+
import { install } from "@jdxcode/aube-node"
|
|
8
|
+
|
|
9
|
+
const result = await install(projectDirectory, {
|
|
10
|
+
add: [
|
|
11
|
+
{ name: "react", version: "19.1.0" },
|
|
12
|
+
{ name: "typescript", version: "5.9.3", dev: true },
|
|
13
|
+
],
|
|
14
|
+
signal: abortController.signal,
|
|
15
|
+
onEvent(event) {
|
|
16
|
+
switch (event.kind) {
|
|
17
|
+
case "phase":
|
|
18
|
+
console.log(event.phase)
|
|
19
|
+
break
|
|
20
|
+
case "progress":
|
|
21
|
+
console.log(event.resolved, event.downloaded)
|
|
22
|
+
break
|
|
23
|
+
case "output":
|
|
24
|
+
console.log(event.level, event.code, event.message)
|
|
25
|
+
break
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
})
|
|
29
|
+
|
|
30
|
+
console.log(result.durationMs)
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
The addon creates an empty package manifest when needed, saves added packages
|
|
34
|
+
at exact versions, and installs declared dependencies. Added entries with
|
|
35
|
+
`dev: true` are saved to `devDependencies`. Root and dependency lifecycle
|
|
36
|
+
scripts are always skipped. Registry/auth settings and dependency-section
|
|
37
|
+
omission come from the project's `.npmrc`; `omit=dev` and `omit=optional` are
|
|
38
|
+
honored.
|
|
39
|
+
|
|
40
|
+
Independent projects install concurrently using invocation-scoped state.
|
|
41
|
+
Operations targeting the same workspace serialize on its project lock.
|
|
42
|
+
`onEvent` uses a non-blocking Node-API thread-safe function, and `signal`
|
|
43
|
+
cooperatively cancels at a safe install boundary.
|
|
44
|
+
|
|
45
|
+
Rejected promises are `AubeError` objects with a stable `code` and a
|
|
46
|
+
human-readable `diagnostic`. Published `ERR_AUBE_*` values follow aube's
|
|
47
|
+
[error-code stability policy](https://github.com/jdx/aube/blob/main/docs/error-codes.md).
|
|
48
|
+
|
|
49
|
+
## Compiled Bun executables
|
|
50
|
+
|
|
51
|
+
Add `bunPlugin({ os, arch, libc })` from `@jdxcode/aube-node/bun-plugin` to each
|
|
52
|
+
target's `Bun.build` plugins. The plugin resolves the root import to the
|
|
53
|
+
selected native platform package so each executable embeds one addon.
|
|
54
|
+
|
|
55
|
+
Cross-compilation hosts must install every optional platform package before
|
|
56
|
+
building targets for other operating systems and architectures:
|
|
57
|
+
|
|
58
|
+
```sh
|
|
59
|
+
bun install --os="*" --cpu="*" @jdxcode/aube-node@$AUBE_NODE_VERSION
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
## Compatibility and stability
|
|
63
|
+
|
|
64
|
+
- The addon targets Node-API 8.
|
|
65
|
+
- Node.js 18 and newer are supported.
|
|
66
|
+
- Bun 1.3.11 is exercised by direct and compiled-executable smoke tests.
|
|
67
|
+
- macOS arm64/x64, Windows arm64/x64, Linux glibc arm64/x64, and Linux musl
|
|
68
|
+
arm64/x64 packages are published.
|
|
69
|
+
- Package versions track the aube workspace version.
|
|
70
|
+
- The TypeScript API follows semantic versioning; stable error identifiers are
|
|
71
|
+
not removed or repurposed.
|
|
72
|
+
|
|
73
|
+
## Development
|
|
74
|
+
|
|
75
|
+
Run the direct Bun and compiled-executable smoke tests from the repository
|
|
76
|
+
root:
|
|
77
|
+
|
|
78
|
+
```sh
|
|
79
|
+
crates/aube-node/poc/run.sh
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
CI also installs the generated npm tarballs in Node and Bun consumers and
|
|
83
|
+
type-checks the public declarations. For support, use
|
|
84
|
+
[GitHub Discussions](https://github.com/jdx/aube/discussions).
|
package/aube.node
ADDED
|
Binary file
|
package/package.json
CHANGED
|
@@ -1,8 +1,22 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jdxcode/aube-node-linux-arm64-musl",
|
|
3
|
-
"version": "
|
|
4
|
-
"description": "
|
|
3
|
+
"version": "1.28.0",
|
|
4
|
+
"description": "Platform addon for @jdxcode/aube-node; install the root package instead",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": "https://github.com/jdx/aube",
|
|
7
|
-
"main": "
|
|
7
|
+
"main": "aube.node",
|
|
8
|
+
"files": [
|
|
9
|
+
"aube.node",
|
|
10
|
+
"README.md"
|
|
11
|
+
],
|
|
12
|
+
"preferUnplugged": true,
|
|
13
|
+
"os": [
|
|
14
|
+
"linux"
|
|
15
|
+
],
|
|
16
|
+
"cpu": [
|
|
17
|
+
"arm64"
|
|
18
|
+
],
|
|
19
|
+
"libc": [
|
|
20
|
+
"musl"
|
|
21
|
+
]
|
|
8
22
|
}
|
package/index.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
throw new Error("@jdxcode/aube-node-linux-arm64-musl 0.0.1-placeholder is a placeholder published to reserve the package name; install a real release instead: https://github.com/jdx/aube")
|