@corca-org/ceal-host 1.0.8 → 1.0.10
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 +2 -2
- package/package.json +5 -10
- package/bin/ceal-host.js +0 -2
- package/bin/launch.js +0 -55
package/README.md
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
# @corca-org/ceal-host
|
|
2
2
|
|
|
3
|
-
The Ceal Host
|
|
3
|
+
The nested Ceal Host payload selector for supported platforms. It is installed by `@corca-org/ceal` and intentionally registers no global command.
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
Install `@corca-org/ceal` to receive the sole global `ceal-host` launcher. A machine migrating from an older direct installation removes this package registration without running lifecycle uninstall, then installs `@corca-org/ceal` and uses its launcher to repair the existing activation.
|
package/package.json
CHANGED
|
@@ -1,28 +1,23 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@corca-org/ceal-host",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.10",
|
|
4
4
|
"description": "The Ceal Host lifecycle client",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"engines": {
|
|
8
8
|
"node": ">=22.19.0"
|
|
9
9
|
},
|
|
10
|
-
"bin": {
|
|
11
|
-
"ceal-host": "bin/ceal-host.js"
|
|
12
|
-
},
|
|
13
10
|
"optionalDependencies": {
|
|
14
|
-
"@corca-org/ceal-host-linux-x64": "1.0.
|
|
15
|
-
"@corca-org/ceal-host-linux-arm64": "1.0.
|
|
16
|
-
"@corca-org/ceal-host-darwin-arm64": "1.0.
|
|
17
|
-
"@corca-org/ceal-host-win32-x64": "1.0.
|
|
11
|
+
"@corca-org/ceal-host-linux-x64": "1.0.10",
|
|
12
|
+
"@corca-org/ceal-host-linux-arm64": "1.0.10",
|
|
13
|
+
"@corca-org/ceal-host-darwin-arm64": "1.0.10",
|
|
14
|
+
"@corca-org/ceal-host-win32-x64": "1.0.10"
|
|
18
15
|
},
|
|
19
16
|
"repository": {
|
|
20
17
|
"type": "git",
|
|
21
18
|
"url": "https://github.com/corca-ai/ceal.git"
|
|
22
19
|
},
|
|
23
20
|
"files": [
|
|
24
|
-
"bin",
|
|
25
|
-
"bin/launch.js",
|
|
26
21
|
"README.md"
|
|
27
22
|
],
|
|
28
23
|
"publishConfig": {
|
package/bin/ceal-host.js
DELETED
package/bin/launch.js
DELETED
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Meta-package bin/launch.js files are replaced with this module during
|
|
3
|
-
* assembly. The tracked bridge points here for source-tree development; the
|
|
4
|
-
* published copy is self-contained and never imports ../../shared/launch.js.
|
|
5
|
-
*/
|
|
6
|
-
import process from "node:process";
|
|
7
|
-
import { createRequire } from "node:module";
|
|
8
|
-
import { dirname, join } from "node:path";
|
|
9
|
-
import { constants as osConstants } from "node:os";
|
|
10
|
-
import { spawn } from "node:child_process";
|
|
11
|
-
|
|
12
|
-
const require = createRequire(import.meta.url);
|
|
13
|
-
|
|
14
|
-
export function launch(input) {
|
|
15
|
-
const platform = `${process.platform}-${process.arch === "x64" ? "x64" : process.arch}`;
|
|
16
|
-
if (!input.supported.includes(platform)) return refuse(input.product, `unsupported platform ${platform}; supported platforms: ${input.supported.join(", ")}.`);
|
|
17
|
-
let packageRoot;
|
|
18
|
-
try {
|
|
19
|
-
packageRoot = dirname(require.resolve(`@corca-org/${input.meta}-${platform}/package.json`));
|
|
20
|
-
} catch {
|
|
21
|
-
return refuse(input.product, `platform package @corca-org/${input.meta}-${platform} is unavailable for ${platform}; supported platforms: ${input.supported.join(", ")}.`);
|
|
22
|
-
}
|
|
23
|
-
const executableName = process.platform === "win32" ? `${input.binaryName}.exe` : input.binaryName;
|
|
24
|
-
const launcherPath = process.env.CEAL_LAUNCHER_PATH ?? process.argv[1] ?? null;
|
|
25
|
-
let companionEnvironment = {};
|
|
26
|
-
if (input.companion) {
|
|
27
|
-
try {
|
|
28
|
-
const root = dirname(require.resolve(`${input.companion.packageName}/package.json`));
|
|
29
|
-
companionEnvironment[input.companion.env] = join(root, input.companion.entry);
|
|
30
|
-
} catch {
|
|
31
|
-
return refuse(input.product, `required package ${input.companion.packageName} is unavailable.`);
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
const child = spawn(join(packageRoot, "bin", executableName), process.argv.slice(2), {
|
|
35
|
-
stdio: "inherit",
|
|
36
|
-
windowsHide: process.platform === "win32" ? false : undefined,
|
|
37
|
-
env: { ...process.env, ...companionEnvironment, ...(launcherPath === null ? {} : { CEAL_LAUNCHER_PATH: launcherPath }) },
|
|
38
|
-
});
|
|
39
|
-
child.once("error", (error) => {
|
|
40
|
-
process.stderr.write(`${input.product}: could not start the platform binary: ${error.message}\n`);
|
|
41
|
-
process.exit(1);
|
|
42
|
-
});
|
|
43
|
-
child.once("exit", (code, signal) => {
|
|
44
|
-
if (signal !== null && process.platform !== "win32") {
|
|
45
|
-
process.kill(process.pid, signal);
|
|
46
|
-
process.exit(128 + (osConstants.signals[signal] ?? 1));
|
|
47
|
-
}
|
|
48
|
-
process.exit(code ?? 1);
|
|
49
|
-
});
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
function refuse(product, message) {
|
|
53
|
-
process.stderr.write(`${product}: ${message}\n`);
|
|
54
|
-
process.exit(1);
|
|
55
|
-
}
|