@fabr-client/core 0.0.1 → 0.0.2
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 +39 -17
- package/bin/fabr-client.js +19 -19
- package/package.json +20 -20
package/README.md
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
# Fabr Client
|
|
2
|
-
|
|
3
|
-
Cross-platform launcher for Fabr Client.
|
|
1
|
+
# Fabr Client
|
|
2
|
+
|
|
3
|
+
Cross-platform launcher for Fabr Client.
|
|
4
4
|
|
|
5
5
|
## Install
|
|
6
6
|
|
|
7
7
|
```bash
|
|
8
|
-
npm install -g @fabr-client/core
|
|
8
|
+
npm install -g @fabr-client/core
|
|
9
9
|
```
|
|
10
10
|
|
|
11
11
|
## Pair And Run
|
|
@@ -13,35 +13,57 @@ npm install -g @fabr-client/core
|
|
|
13
13
|
Copy the pairing command from Navinora system settings, then run:
|
|
14
14
|
|
|
15
15
|
```bash
|
|
16
|
-
fabr-client login --server https://pivot.enclaws.com --pairing-code <code>
|
|
17
|
-
fabr-client run
|
|
16
|
+
fabr-client login --server https://pivot.enclaws.com --pairing-code <code>
|
|
17
|
+
fabr-client run
|
|
18
18
|
```
|
|
19
19
|
|
|
20
20
|
The main package is a thin launcher. It installs the matching native payload
|
|
21
21
|
through platform-specific optional dependencies, so end users only need the one
|
|
22
|
-
global install command above.
|
|
22
|
+
global install command above. Each platform payload contains `bin/fabr-client`
|
|
23
|
+
plus the managed Codex Runtime executable at `bin/runtime/codex` (`.exe` on
|
|
24
|
+
Windows).
|
|
23
25
|
|
|
24
26
|
## Platform Support
|
|
25
27
|
|
|
26
28
|
Published platform packages:
|
|
27
29
|
|
|
28
|
-
- `@fabr-client/core-win32-x64`
|
|
29
|
-
- `@fabr-client/core-darwin-x64`
|
|
30
|
-
- `@fabr-client/core-darwin-arm64`
|
|
30
|
+
- `@fabr-client/core-win32-x64`
|
|
31
|
+
- `@fabr-client/core-darwin-x64`
|
|
32
|
+
- `@fabr-client/core-darwin-arm64`
|
|
31
33
|
|
|
32
34
|
## Publish Checklist
|
|
33
35
|
|
|
34
|
-
|
|
36
|
+
Set the shared Rust and npm package version first:
|
|
37
|
+
|
|
38
|
+
```powershell
|
|
39
|
+
pwsh ./scripts/set-package-version.ps1 -Version 0.0.3
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
For maintainers, build the Windows payload with PowerShell:
|
|
43
|
+
|
|
44
|
+
```powershell
|
|
45
|
+
pwsh ./scripts/package-fabr-client.ps1 `
|
|
46
|
+
-Profile release `
|
|
47
|
+
-PackNpm `
|
|
48
|
+
-CodexRuntimeMode build `
|
|
49
|
+
-CodexRuntimeRepo C:\path\to\codex-runtime
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
On macOS, build both `darwin-x64` and `darwin-arm64` payloads:
|
|
35
53
|
|
|
36
54
|
```bash
|
|
37
|
-
|
|
38
|
-
|
|
55
|
+
./scripts/package-macos-all.sh \
|
|
56
|
+
--profile release \
|
|
57
|
+
--pack-npm \
|
|
58
|
+
--codex-runtime-mode build \
|
|
59
|
+
--codex-runtime-repo /path/to/codex-runtime
|
|
60
|
+
```
|
|
39
61
|
|
|
40
|
-
|
|
41
|
-
node ./packaging/npm/bin/fabr-client.js --help
|
|
42
|
-
npm pack ./packaging/npm
|
|
62
|
+
Validate and publish:
|
|
43
63
|
|
|
44
|
-
|
|
64
|
+
```bash
|
|
65
|
+
node ./packaging/npm/bin/fabr-client.js --help
|
|
66
|
+
npm pack ./packaging/npm
|
|
45
67
|
npm publish ./packaging/npm-platforms/win32-x64 --access public
|
|
46
68
|
npm publish ./packaging/npm-platforms/darwin-x64 --access public
|
|
47
69
|
npm publish ./packaging/npm-platforms/darwin-arm64 --access public
|
package/bin/fabr-client.js
CHANGED
|
@@ -5,15 +5,15 @@ const { spawnSync } = require("node:child_process");
|
|
|
5
5
|
const fs = require("node:fs");
|
|
6
6
|
const path = require("node:path");
|
|
7
7
|
|
|
8
|
-
const platform = process.platform;
|
|
9
|
-
const arch = process.arch;
|
|
10
|
-
const exe = platform === "win32" ? "fabr-client.exe" : "fabr-client";
|
|
11
|
-
const platformDir = `${platform}-${arch}`;
|
|
12
|
-
const packageByPlatform = {
|
|
13
|
-
"win32-x64": "@fabr-client/core-win32-x64",
|
|
14
|
-
"darwin-x64": "@fabr-client/core-darwin-x64",
|
|
15
|
-
"darwin-arm64": "@fabr-client/core-darwin-arm64",
|
|
16
|
-
};
|
|
8
|
+
const platform = process.platform;
|
|
9
|
+
const arch = process.arch;
|
|
10
|
+
const exe = platform === "win32" ? "fabr-client.exe" : "fabr-client";
|
|
11
|
+
const platformDir = `${platform}-${arch}`;
|
|
12
|
+
const packageByPlatform = {
|
|
13
|
+
"win32-x64": "@fabr-client/core-win32-x64",
|
|
14
|
+
"darwin-x64": "@fabr-client/core-darwin-x64",
|
|
15
|
+
"darwin-arm64": "@fabr-client/core-darwin-arm64",
|
|
16
|
+
};
|
|
17
17
|
|
|
18
18
|
function resolvePlatformPackageBinary() {
|
|
19
19
|
const pkg = packageByPlatform[platformDir];
|
|
@@ -27,9 +27,9 @@ function resolvePlatformPackageBinary() {
|
|
|
27
27
|
}
|
|
28
28
|
}
|
|
29
29
|
|
|
30
|
-
const candidates = [
|
|
31
|
-
process.env.FABR_CLIENT_BIN,
|
|
32
|
-
resolvePlatformPackageBinary(),
|
|
30
|
+
const candidates = [
|
|
31
|
+
process.env.FABR_CLIENT_BIN,
|
|
32
|
+
resolvePlatformPackageBinary(),
|
|
33
33
|
// Local development fallback: package payloads staged next to this repo.
|
|
34
34
|
path.join(__dirname, "..", "..", "npm-platforms", platformDir, "bin", exe),
|
|
35
35
|
path.join(__dirname, platformDir, exe),
|
|
@@ -39,13 +39,13 @@ const candidates = [
|
|
|
39
39
|
|
|
40
40
|
const binary = candidates.find((candidate) => fs.existsSync(candidate));
|
|
41
41
|
|
|
42
|
-
if (!binary) {
|
|
43
|
-
console.error(
|
|
44
|
-
`Fabr Client does not include a binary for ${platformDir}.\n` +
|
|
45
|
-
"Please reinstall @fabr-client/core, or install the matching platform package."
|
|
46
|
-
);
|
|
47
|
-
process.exit(1);
|
|
48
|
-
}
|
|
42
|
+
if (!binary) {
|
|
43
|
+
console.error(
|
|
44
|
+
`Fabr Client does not include a binary for ${platformDir}.\n` +
|
|
45
|
+
"Please reinstall @fabr-client/core, or install the matching platform package."
|
|
46
|
+
);
|
|
47
|
+
process.exit(1);
|
|
48
|
+
}
|
|
49
49
|
|
|
50
50
|
const result = spawnSync(binary, process.argv.slice(2), {
|
|
51
51
|
stdio: "inherit",
|
package/package.json
CHANGED
|
@@ -1,41 +1,41 @@
|
|
|
1
1
|
{
|
|
2
|
-
"name": "@fabr-client/core",
|
|
3
|
-
"version": "0.0.
|
|
4
|
-
"description": "Cross-platform launcher for Fabr Client",
|
|
2
|
+
"name": "@fabr-client/core",
|
|
3
|
+
"version": "0.0.2",
|
|
4
|
+
"description": "Cross-platform launcher for Fabr Client",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"homepage": "https://pivot.enclaws.com",
|
|
7
7
|
"repository": {
|
|
8
8
|
"type": "git",
|
|
9
|
-
"url": "git+https://github.com/hashSTACS-Global/fabr-client.git"
|
|
9
|
+
"url": "git+https://github.com/hashSTACS-Global/fabr-client.git"
|
|
10
10
|
},
|
|
11
11
|
"bugs": {
|
|
12
|
-
"url": "https://github.com/hashSTACS-Global/fabr-client/issues"
|
|
12
|
+
"url": "https://github.com/hashSTACS-Global/fabr-client/issues"
|
|
13
13
|
},
|
|
14
14
|
"bin": {
|
|
15
|
-
"fabr-client": "bin/fabr-client.js"
|
|
15
|
+
"fabr-client": "bin/fabr-client.js"
|
|
16
16
|
},
|
|
17
17
|
"scripts": {
|
|
18
|
-
"smoke": "node bin/fabr-client.js --help"
|
|
18
|
+
"smoke": "node bin/fabr-client.js --help"
|
|
19
19
|
},
|
|
20
20
|
"optionalDependencies": {
|
|
21
|
-
"@fabr-client/core-win32-x64": "0.0.
|
|
22
|
-
"@fabr-client/core-darwin-x64": "0.0.
|
|
23
|
-
"@fabr-client/core-darwin-arm64": "0.0.
|
|
21
|
+
"@fabr-client/core-win32-x64": "0.0.2",
|
|
22
|
+
"@fabr-client/core-darwin-x64": "0.0.2",
|
|
23
|
+
"@fabr-client/core-darwin-arm64": "0.0.2"
|
|
24
24
|
},
|
|
25
25
|
"files": [
|
|
26
26
|
"bin/",
|
|
27
27
|
"README.md"
|
|
28
28
|
],
|
|
29
|
-
"engines": {
|
|
30
|
-
"node": ">=18"
|
|
31
|
-
},
|
|
32
|
-
"publishConfig": {
|
|
33
|
-
"access": "public"
|
|
34
|
-
},
|
|
35
|
-
"os": [
|
|
36
|
-
"darwin",
|
|
37
|
-
"win32"
|
|
38
|
-
],
|
|
29
|
+
"engines": {
|
|
30
|
+
"node": ">=18"
|
|
31
|
+
},
|
|
32
|
+
"publishConfig": {
|
|
33
|
+
"access": "public"
|
|
34
|
+
},
|
|
35
|
+
"os": [
|
|
36
|
+
"darwin",
|
|
37
|
+
"win32"
|
|
38
|
+
],
|
|
39
39
|
"cpu": [
|
|
40
40
|
"arm64",
|
|
41
41
|
"x64"
|