cawide 0.11.1 → 0.12.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 (2) hide show
  1. package/bin/cawide.js +10 -3
  2. package/package.json +8 -6
package/bin/cawide.js CHANGED
@@ -10,12 +10,14 @@ const PLATFORM_PACKAGES = {
10
10
  "darwin-x64": "cawide-darwin-x64",
11
11
  "linux-x64": "cawide-linux-x64",
12
12
  "linux-arm64": "cawide-linux-arm64",
13
+ "win32-x64": "cawide-win32-x64",
14
+ "win32-arm64": "cawide-win32-x64",
13
15
  };
14
16
 
15
17
  const SIGNAL_EXIT_CODES = { SIGINT: 130, SIGTERM: 143 };
16
18
 
17
19
  function executableName() {
18
- return "cawide";
20
+ return process.platform === "win32" ? "cawide.exe" : "cawide";
19
21
  }
20
22
 
21
23
  function platformKey() {
@@ -26,7 +28,7 @@ function platformPackageName() {
26
28
  const packageName = PLATFORM_PACKAGES[platformKey()];
27
29
  if (!packageName) {
28
30
  throw new Error(
29
- `${platformKey()} is not supported yet (supported: macOS and Linux on x64/arm64).`
31
+ `${platformKey()} is not supported yet (supported: macOS, Linux, and Windows on x64/arm64).`
30
32
  );
31
33
  }
32
34
  return packageName;
@@ -67,7 +69,12 @@ function run(binaryPath) {
67
69
  : 1);
68
70
  process.exit(signalCode);
69
71
  }
70
- process.exit(result.status ?? 0);
72
+ let status = result.status ?? 0;
73
+ // On Windows, 0xC000013A (STATUS_CONTROL_C_EXIT) is reported as -1073741510 or 3221225786
74
+ if (status === -1073741510 || status === 3221225786) {
75
+ status = 130;
76
+ }
77
+ process.exit(status);
71
78
  }
72
79
 
73
80
  function main() {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cawide",
3
- "version": "0.11.1",
3
+ "version": "0.12.0",
4
4
  "description": "Run your terminal and AI coding agents on your computer, drive them from your iPhone.",
5
5
  "homepage": "https://github.com/Hermillon/cawide",
6
6
  "license": "MIT",
@@ -16,16 +16,18 @@
16
16
  },
17
17
  "os": [
18
18
  "darwin",
19
- "linux"
19
+ "linux",
20
+ "win32"
20
21
  ],
21
22
  "cpu": [
22
23
  "x64",
23
24
  "arm64"
24
25
  ],
25
26
  "optionalDependencies": {
26
- "cawide-darwin-arm64": "0.11.1",
27
- "cawide-darwin-x64": "0.11.1",
28
- "cawide-linux-x64": "0.11.1",
29
- "cawide-linux-arm64": "0.11.1"
27
+ "cawide-darwin-arm64": "0.12.0",
28
+ "cawide-darwin-x64": "0.12.0",
29
+ "cawide-linux-x64": "0.12.0",
30
+ "cawide-linux-arm64": "0.12.0",
31
+ "cawide-win32-x64": "0.12.0"
30
32
  }
31
33
  }