cawide 0.4.7 → 0.7.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.
Files changed (3) hide show
  1. package/README.md +33 -12
  2. package/bin/cawide.js +5 -31
  3. package/package.json +21 -18
package/README.md CHANGED
@@ -1,29 +1,50 @@
1
1
  # cawide
2
2
 
3
- Mobile remote code editor & AI agent terminal companion.
3
+ Run your terminal and AI coding agents on your computer, drive them from your iPhone.
4
4
 
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
-
7
- ## Install
5
+ ## Installation
8
6
 
9
7
  ```bash
10
8
  npm install -g cawide
11
9
  ```
12
10
 
13
- Or run directly without installing:
11
+ ## Quick Start
12
+
13
+ Start Cawide for your project workspace:
14
14
 
15
15
  ```bash
16
- npx cawide --help
16
+ cawide serve --workdir ~/your-project
17
17
  ```
18
18
 
19
- ## Getting Started
19
+ Then scan the QR code with the Cawide iOS app to connect.
20
20
 
21
+ ## Commands
22
+
23
+ ### Pairing
24
+ Print a pairing QR code and link for an already running daemon:
21
25
  ```bash
22
- # Start the workspace daemon
23
- cawide start
26
+ cawide pair
27
+ ```
24
28
 
25
- # Print pairing QR code
26
- cawide qr
29
+ ### Agent Integration Setup
30
+ Install hooks or configurations for your favorite coding agents:
31
+ ```bash
32
+ cawide setup claude|codex|omp|opencode
27
33
  ```
28
34
 
29
- For full documentation, visit [cawide.hermillon.com](https://cawide.hermillon.com).
35
+ ### Connected Devices
36
+ List authorized mobile devices:
37
+ ```bash
38
+ cawide devices
39
+ ```
40
+
41
+ Revoke access for a specific device:
42
+ ```bash
43
+ cawide revoke <device>
44
+ ```
45
+
46
+ ### Stop Daemon
47
+ Stop the running Cawide daemon:
48
+ ```bash
49
+ cawide stop
50
+ ```
package/bin/cawide.js CHANGED
@@ -5,54 +5,28 @@ const os = require("node:os");
5
5
  const path = require("node:path");
6
6
  const childProcess = require("node:child_process");
7
7
 
8
- // Maps `${process.platform}-${process.arch}` to the platform-specific npm
9
- // package that ships the prebuilt binary for it (see
10
- // scripts/package-npm.js and the six `cawide-<platform>`
11
- // optionalDependencies in package.json).
12
8
  const PLATFORM_PACKAGES = {
13
9
  "darwin-arm64": "cawide-darwin-arm64",
14
10
  "darwin-x64": "cawide-darwin-x64",
15
11
  "linux-x64": "cawide-linux-x64",
16
12
  "linux-arm64": "cawide-linux-arm64",
17
- "win32-x64": "cawide-win32-x64",
18
- "win32-arm64": "cawide-win32-x64",
19
13
  };
14
+
20
15
  const SIGNAL_EXIT_CODES = { SIGINT: 130, SIGTERM: 143 };
21
16
 
22
17
  function executableName() {
23
- return process.platform === "win32" ? "cawide.exe" : "cawide";
18
+ return "cawide";
24
19
  }
25
20
 
26
21
  function platformKey() {
27
22
  return `${process.platform}-${process.arch}`;
28
23
  }
29
24
 
30
- function localBinary() {
31
- const repositoryRoot = path.resolve(__dirname, "../../..");
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
- }
41
-
42
- for (const profile of ["release", "debug"]) {
43
- const candidate = path.join(repositoryRoot, "target", profile, executableName());
44
- if (fs.existsSync(candidate)) return candidate;
45
- }
46
- return null;
47
- }
48
-
49
25
  function platformPackageName() {
50
26
  const packageName = PLATFORM_PACKAGES[platformKey()];
51
27
  if (!packageName) {
52
28
  throw new Error(
53
- `Cawide does not provide a binary for ${process.platform}/${process.arch}. Supported platforms: ${Object.keys(
54
- PLATFORM_PACKAGES
55
- ).join(", ")}.`
29
+ `${platformKey()} is not supported yet (supported: macOS and Linux on x64/arm64).`
56
30
  );
57
31
  }
58
32
  return packageName;
@@ -88,7 +62,7 @@ function run(binaryPath) {
88
62
  if (result.signal) {
89
63
  const signalCode =
90
64
  SIGNAL_EXIT_CODES[result.signal] ||
91
- (process.platform !== "win32" && os.constants?.signals?.[result.signal]
65
+ (os.constants?.signals?.[result.signal]
92
66
  ? 128 + os.constants.signals[result.signal]
93
67
  : 1);
94
68
  process.exit(signalCode);
@@ -97,7 +71,7 @@ function run(binaryPath) {
97
71
  }
98
72
 
99
73
  function main() {
100
- run(localBinary() || resolvePlatformBinary());
74
+ run(resolvePlatformBinary());
101
75
  }
102
76
 
103
77
  try {
package/package.json CHANGED
@@ -1,28 +1,31 @@
1
1
  {
2
2
  "name": "cawide",
3
- "version": "0.4.7",
4
- "description": "Mobile remote code editor & AI agent terminal companion",
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
- },
3
+ "version": "0.7.0",
4
+ "description": "Run your terminal and AI coding agents on your computer, drive them from your iPhone.",
5
+ "homepage": "https://github.com/Hermillon/cawide",
6
+ "license": "MIT",
11
7
  "bin": {
12
8
  "cawide": "bin/cawide.js"
13
9
  },
14
- "files": ["bin/", "README.md"],
10
+ "files": [
11
+ "bin/",
12
+ "README.md"
13
+ ],
15
14
  "engines": {
16
- "node": ">=16.0.0"
15
+ "node": ">=18"
17
16
  },
18
- "keywords": ["cawide", "terminal", "ai-agent", "remote-editor", "mobile", "editor"],
19
- "author": "Cawide Team <support@hermillon.com>",
20
- "license": "MIT",
17
+ "os": [
18
+ "darwin",
19
+ "linux"
20
+ ],
21
+ "cpu": [
22
+ "x64",
23
+ "arm64"
24
+ ],
21
25
  "optionalDependencies": {
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"
26
+ "cawide-darwin-arm64": "0.7.0",
27
+ "cawide-darwin-x64": "0.7.0",
28
+ "cawide-linux-x64": "0.7.0",
29
+ "cawide-linux-arm64": "0.7.0"
27
30
  }
28
31
  }