@posoco/cetas 0.5.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/README.md +13 -0
- package/bin/cetas.js +35 -0
- package/package.json +21 -0
package/README.md
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
# cetas
|
|
2
|
+
|
|
3
|
+
Bun-runtime host for cetas — a provider-neutral posoco agent with a pi-tui
|
|
4
|
+
terminal UI, distributed as a prebuilt native binary (https://github.com/colmugx/cetas).
|
|
5
|
+
|
|
6
|
+
## Install
|
|
7
|
+
|
|
8
|
+
npm install -g @posoco/cetas
|
|
9
|
+
|
|
10
|
+
Supported platforms: darwin-arm64, linux-x64, windows-x64. Each installs via
|
|
11
|
+
an optional dependency carrying its binary; on other platforms only this
|
|
12
|
+
launcher installs and reports the supported list. The launcher itself runs
|
|
13
|
+
under Node.js (esbuild-style); the agent binary it execs is self-contained.
|
package/bin/cetas.js
ADDED
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
// cetas launcher: exec the cetas-bun binary for this platform from the
|
|
3
|
+
// matching cetas-<os>-<arch> payload package. Runs under Node.js.
|
|
4
|
+
const { spawnSync } = require("node:child_process");
|
|
5
|
+
|
|
6
|
+
const OS = { darwin: "darwin", linux: "linux", win32: "windows" }[process.platform];
|
|
7
|
+
const supported = ["darwin-arm64", "linux-x64", "windows-x64"];
|
|
8
|
+
const target = OS ? `${OS}-${process.arch}` : null;
|
|
9
|
+
|
|
10
|
+
if (!supported.includes(target)) {
|
|
11
|
+
console.error(
|
|
12
|
+
`cetas: unsupported platform ${process.platform}-${process.arch} ` +
|
|
13
|
+
`(supported: ${supported.join(", ")})`,
|
|
14
|
+
);
|
|
15
|
+
process.exit(1);
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
const pkg = `cetas-${target}`;
|
|
19
|
+
let bin;
|
|
20
|
+
try {
|
|
21
|
+
bin = require.resolve(`${pkg}/cetas-bun${process.platform === "win32" ? ".exe" : ""}`);
|
|
22
|
+
} catch {
|
|
23
|
+
console.error(
|
|
24
|
+
`cetas: payload package ${pkg} is missing ` +
|
|
25
|
+
`(skipped as an optional dependency? try: npm install ${pkg})`,
|
|
26
|
+
);
|
|
27
|
+
process.exit(1);
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
const result = spawnSync(bin, process.argv.slice(2), { stdio: "inherit" });
|
|
31
|
+
if (result.error) {
|
|
32
|
+
console.error(`cetas: failed to launch ${bin}: ${result.error.message}`);
|
|
33
|
+
process.exit(1);
|
|
34
|
+
}
|
|
35
|
+
process.exit(result.status ?? 1);
|
package/package.json
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@posoco/cetas",
|
|
3
|
+
"version": "0.5.1",
|
|
4
|
+
"description": "Bun-runtime host for cetas — provider-neutral posoco agent with pi-tui",
|
|
5
|
+
"license": "Apache-2.0",
|
|
6
|
+
"repository": {
|
|
7
|
+
"type": "git",
|
|
8
|
+
"url": "git+https://github.com/colmugx/cetas.git"
|
|
9
|
+
},
|
|
10
|
+
"bin": {
|
|
11
|
+
"cetas": "bin/cetas.js"
|
|
12
|
+
},
|
|
13
|
+
"files": [
|
|
14
|
+
"bin"
|
|
15
|
+
],
|
|
16
|
+
"optionalDependencies": {
|
|
17
|
+
"cetas-darwin-arm64": "0.5.1",
|
|
18
|
+
"cetas-linux-x64": "0.5.1",
|
|
19
|
+
"cetas-windows-x64": "0.5.1"
|
|
20
|
+
}
|
|
21
|
+
}
|