cawide 0.4.6 → 0.4.7
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 +17 -51
- package/bin/cawide.js +22 -10
- package/package.json +15 -22
package/README.md
CHANGED
|
@@ -1,63 +1,29 @@
|
|
|
1
|
-
#
|
|
1
|
+
# cawide
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Mobile remote code editor & AI agent terminal companion.
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
Control your local development environment, terminals, and AI coding agents (Claude Code, OpenAI Codex, OpenCode, Pi, OMP, Hermes) directly from the Cawide mobile app.
|
|
6
6
|
|
|
7
|
-
##
|
|
7
|
+
## Install
|
|
8
8
|
|
|
9
|
-
```
|
|
10
|
-
# Run directly via npx
|
|
11
|
-
npx cawide start
|
|
12
|
-
|
|
13
|
-
# Or install globally
|
|
9
|
+
```bash
|
|
14
10
|
npm install -g cawide
|
|
15
|
-
cawide start
|
|
16
11
|
```
|
|
17
12
|
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
| Command | Description |
|
|
21
|
-
|---------|-------------|
|
|
22
|
-
| `cawide start` | Start the daemon in your project directory and display the pairing QR code. |
|
|
23
|
-
| `cawide qr` | Show the pairing QR code for the active workspace. |
|
|
24
|
-
| `cawide status` | Inspect connected sessions, active terminals, and relay status. |
|
|
25
|
-
| `cawide setup [agent]` | Configure hooks and skills for AI agents (Claude, Codex, OpenCode). |
|
|
26
|
-
| `cawide logs` | View daemon logs. |
|
|
27
|
-
| `cawide stop` | Stop the background daemon. |
|
|
28
|
-
|
|
29
|
-
Use `cawide <command> --help` for the options supported by a particular command.
|
|
30
|
-
|
|
31
|
-
## Security & Architecture
|
|
32
|
-
|
|
33
|
-
- **Peer-to-peer QUIC / UDP** direct connection with automatic relay fallback.
|
|
34
|
-
- **Ed25519** cryptographic challenge-response authentication.
|
|
35
|
-
- **End-to-end encrypted** transport — your code never passes through third-party servers unencrypted.
|
|
13
|
+
Or run directly without installing:
|
|
36
14
|
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
of this package (the same approach used by esbuild and `@biomejs/biome`) — no
|
|
41
|
-
extra download step at runtime.
|
|
42
|
-
|
|
43
|
-
| Platform | Package |
|
|
44
|
-
|----------|---------|
|
|
45
|
-
| macOS (Apple Silicon) | [`cawide-darwin-arm64`](https://www.npmjs.com/package/cawide-darwin-arm64) |
|
|
46
|
-
| macOS (Intel) | [`cawide-darwin-x64`](https://www.npmjs.com/package/cawide-darwin-x64) |
|
|
47
|
-
| Linux (x86_64) | [`cawide-linux-x64`](https://www.npmjs.com/package/cawide-linux-x64) |
|
|
48
|
-
| Linux (ARM64) | [`cawide-linux-arm64`](https://www.npmjs.com/package/cawide-linux-arm64) |
|
|
49
|
-
| Windows (x86_64) | [`cawide-win32-x64`](https://www.npmjs.com/package/cawide-win32-x64) |
|
|
50
|
-
| Windows (ARM64) | [`cawide-win32-arm64`](https://www.npmjs.com/package/cawide-win32-arm64) |
|
|
51
|
-
|
|
52
|
-
If `npm install` was run with `--no-optional`/`--omit=optional`, or the
|
|
53
|
-
platform is unsupported, `cawide` prints a clear error explaining how to
|
|
54
|
-
reinstall.
|
|
15
|
+
```bash
|
|
16
|
+
npx cawide --help
|
|
17
|
+
```
|
|
55
18
|
|
|
56
|
-
##
|
|
19
|
+
## Getting Started
|
|
57
20
|
|
|
58
|
-
|
|
59
|
-
|
|
21
|
+
```bash
|
|
22
|
+
# Start the workspace daemon
|
|
23
|
+
cawide start
|
|
60
24
|
|
|
61
|
-
|
|
25
|
+
# Print pairing QR code
|
|
26
|
+
cawide qr
|
|
27
|
+
```
|
|
62
28
|
|
|
63
|
-
|
|
29
|
+
For full documentation, visit [cawide.hermillon.com](https://cawide.hermillon.com).
|
package/bin/cawide.js
CHANGED
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
3
|
const fs = require("node:fs");
|
|
4
|
+
const os = require("node:os");
|
|
4
5
|
const path = require("node:path");
|
|
5
6
|
const childProcess = require("node:child_process");
|
|
6
7
|
|
|
7
8
|
// Maps `${process.platform}-${process.arch}` to the platform-specific npm
|
|
8
9
|
// package that ships the prebuilt binary for it (see
|
|
9
|
-
// scripts/
|
|
10
|
+
// scripts/package-npm.js and the six `cawide-<platform>`
|
|
10
11
|
// optionalDependencies in package.json).
|
|
11
12
|
const PLATFORM_PACKAGES = {
|
|
12
13
|
"darwin-arm64": "cawide-darwin-arm64",
|
|
@@ -14,7 +15,7 @@ const PLATFORM_PACKAGES = {
|
|
|
14
15
|
"linux-x64": "cawide-linux-x64",
|
|
15
16
|
"linux-arm64": "cawide-linux-arm64",
|
|
16
17
|
"win32-x64": "cawide-win32-x64",
|
|
17
|
-
"win32-arm64": "cawide-win32-
|
|
18
|
+
"win32-arm64": "cawide-win32-x64",
|
|
18
19
|
};
|
|
19
20
|
const SIGNAL_EXIT_CODES = { SIGINT: 130, SIGTERM: 143 };
|
|
20
21
|
|
|
@@ -28,7 +29,15 @@ function platformKey() {
|
|
|
28
29
|
|
|
29
30
|
function localBinary() {
|
|
30
31
|
const repositoryRoot = path.resolve(__dirname, "../../..");
|
|
31
|
-
|
|
32
|
+
const cargoTomlPath = path.join(repositoryRoot, "Cargo.toml");
|
|
33
|
+
if (!fs.existsSync(cargoTomlPath)) return null;
|
|
34
|
+
|
|
35
|
+
try {
|
|
36
|
+
const cargoToml = fs.readFileSync(cargoTomlPath, "utf8");
|
|
37
|
+
if (!cargoToml.includes("cawide")) return null;
|
|
38
|
+
} catch {
|
|
39
|
+
return null;
|
|
40
|
+
}
|
|
32
41
|
|
|
33
42
|
for (const profile of ["release", "debug"]) {
|
|
34
43
|
const candidate = path.join(repositoryRoot, "target", profile, executableName());
|
|
@@ -58,10 +67,7 @@ function resolvePlatformBinary() {
|
|
|
58
67
|
} catch (error) {
|
|
59
68
|
if (error.code === "MODULE_NOT_FOUND") {
|
|
60
69
|
throw new Error(
|
|
61
|
-
`Cawide could not find the "${packageName}" platform package for ${platformKey()}.\
|
|
62
|
-
"This usually happens when the package was installed with --no-optional/--omit=optional, " +
|
|
63
|
-
"npm skipped optional dependencies, or the platform is unsupported.\n" +
|
|
64
|
-
"Try reinstalling without skipping optional dependencies: npm install -g cawide"
|
|
70
|
+
`Cawide could not find the "${packageName}" platform package for ${platformKey()}.\nThis usually happens when the package was installed with --no-optional/--omit=optional, npm skipped optional dependencies, or the platform is unsupported.\nTry reinstalling without skipping optional dependencies: npm install -g cawide`
|
|
65
71
|
);
|
|
66
72
|
}
|
|
67
73
|
throw error;
|
|
@@ -70,8 +76,7 @@ function resolvePlatformBinary() {
|
|
|
70
76
|
const binaryPath = path.join(path.dirname(packageJsonPath), "bin", executableName());
|
|
71
77
|
if (!fs.existsSync(binaryPath)) {
|
|
72
78
|
throw new Error(
|
|
73
|
-
`The "${packageName}" platform package is installed but is missing its binary at ${binaryPath}. `
|
|
74
|
-
"Try reinstalling: npm install -g cawide"
|
|
79
|
+
`The "${packageName}" platform package is installed but is missing its binary at ${binaryPath}. Try reinstalling: npm install -g cawide`
|
|
75
80
|
);
|
|
76
81
|
}
|
|
77
82
|
return binaryPath;
|
|
@@ -80,7 +85,14 @@ function resolvePlatformBinary() {
|
|
|
80
85
|
function run(binaryPath) {
|
|
81
86
|
const result = childProcess.spawnSync(binaryPath, process.argv.slice(2), { stdio: "inherit" });
|
|
82
87
|
if (result.error) throw result.error;
|
|
83
|
-
if (result.signal
|
|
88
|
+
if (result.signal) {
|
|
89
|
+
const signalCode =
|
|
90
|
+
SIGNAL_EXIT_CODES[result.signal] ||
|
|
91
|
+
(process.platform !== "win32" && os.constants?.signals?.[result.signal]
|
|
92
|
+
? 128 + os.constants.signals[result.signal]
|
|
93
|
+
: 1);
|
|
94
|
+
process.exit(signalCode);
|
|
95
|
+
}
|
|
84
96
|
process.exit(result.status ?? 0);
|
|
85
97
|
}
|
|
86
98
|
|
package/package.json
CHANGED
|
@@ -1,35 +1,28 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "cawide",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.7",
|
|
4
4
|
"description": "Mobile remote code editor & AI agent terminal companion",
|
|
5
|
-
"homepage": "https://cawide.
|
|
6
|
-
"bugs": "https://
|
|
5
|
+
"homepage": "https://cawide.hermillon.com",
|
|
6
|
+
"bugs": "https://github.com/Hermillon/cawide/issues",
|
|
7
|
+
"repository": {
|
|
8
|
+
"type": "git",
|
|
9
|
+
"url": "https://github.com/Hermillon/cawide.git"
|
|
10
|
+
},
|
|
7
11
|
"bin": {
|
|
8
12
|
"cawide": "bin/cawide.js"
|
|
9
13
|
},
|
|
10
|
-
"files": [
|
|
11
|
-
"bin/",
|
|
12
|
-
"README.md"
|
|
13
|
-
],
|
|
14
|
+
"files": ["bin/", "README.md"],
|
|
14
15
|
"engines": {
|
|
15
16
|
"node": ">=16.0.0"
|
|
16
17
|
},
|
|
17
|
-
"keywords": [
|
|
18
|
-
|
|
19
|
-
"terminal",
|
|
20
|
-
"ai-agent",
|
|
21
|
-
"remote-editor",
|
|
22
|
-
"mobile",
|
|
23
|
-
"editor"
|
|
24
|
-
],
|
|
25
|
-
"author": "Cawide Team",
|
|
18
|
+
"keywords": ["cawide", "terminal", "ai-agent", "remote-editor", "mobile", "editor"],
|
|
19
|
+
"author": "Cawide Team <support@hermillon.com>",
|
|
26
20
|
"license": "MIT",
|
|
27
21
|
"optionalDependencies": {
|
|
28
|
-
"cawide-darwin-arm64": "0.4.
|
|
29
|
-
"cawide-darwin-x64": "0.4.
|
|
30
|
-
"cawide-linux-x64": "0.4.
|
|
31
|
-
"cawide-linux-arm64": "0.4.
|
|
32
|
-
"cawide-win32-x64": "0.4.
|
|
33
|
-
"cawide-win32-arm64": "0.4.6"
|
|
22
|
+
"cawide-darwin-arm64": "0.4.7",
|
|
23
|
+
"cawide-darwin-x64": "0.4.7",
|
|
24
|
+
"cawide-linux-x64": "0.4.7",
|
|
25
|
+
"cawide-linux-arm64": "0.4.7",
|
|
26
|
+
"cawide-win32-x64": "0.4.7"
|
|
34
27
|
}
|
|
35
28
|
}
|