codeam-cli 1.0.3 → 1.0.5
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/dist/index.js +65 -4
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -106,7 +106,62 @@ var { getConfig, ensurePluginId, addSession, removeSession, setActiveSession, ge
|
|
|
106
106
|
|
|
107
107
|
// src/ui/banner.ts
|
|
108
108
|
var import_picocolors = __toESM(require("picocolors"));
|
|
109
|
-
|
|
109
|
+
|
|
110
|
+
// package.json
|
|
111
|
+
var package_default = {
|
|
112
|
+
name: "codeam-cli",
|
|
113
|
+
version: "1.0.5",
|
|
114
|
+
description: "Remote control Claude Code from your mobile device",
|
|
115
|
+
main: "dist/index.js",
|
|
116
|
+
bin: {
|
|
117
|
+
codeam: "dist/index.js"
|
|
118
|
+
},
|
|
119
|
+
files: [
|
|
120
|
+
"dist",
|
|
121
|
+
"README.md"
|
|
122
|
+
],
|
|
123
|
+
scripts: {
|
|
124
|
+
build: "tsup",
|
|
125
|
+
dev: "tsup --watch",
|
|
126
|
+
test: "vitest run",
|
|
127
|
+
typecheck: "tsc --noEmit",
|
|
128
|
+
postinstall: "node dist/postinstall.js || true",
|
|
129
|
+
prepublishOnly: "npm run build"
|
|
130
|
+
},
|
|
131
|
+
keywords: [
|
|
132
|
+
"claude",
|
|
133
|
+
"claude-code",
|
|
134
|
+
"ai",
|
|
135
|
+
"cli",
|
|
136
|
+
"remote-control",
|
|
137
|
+
"codeagent"
|
|
138
|
+
],
|
|
139
|
+
author: "Edgar Durand",
|
|
140
|
+
repository: {
|
|
141
|
+
type: "git",
|
|
142
|
+
url: "git+https://github.com/edgardurand/codeagent-mobile.git"
|
|
143
|
+
},
|
|
144
|
+
license: "MIT",
|
|
145
|
+
engines: {
|
|
146
|
+
node: ">=18.0.0"
|
|
147
|
+
},
|
|
148
|
+
dependencies: {
|
|
149
|
+
"@clack/prompts": "^0.10.0",
|
|
150
|
+
"node-pty": "^1.0.0",
|
|
151
|
+
picocolors: "^1.1.0",
|
|
152
|
+
ws: "^8.18.0"
|
|
153
|
+
},
|
|
154
|
+
devDependencies: {
|
|
155
|
+
"@types/node": "^22.0.0",
|
|
156
|
+
"@types/ws": "^8.5.0",
|
|
157
|
+
tsup: "^8.0.0",
|
|
158
|
+
typescript: "^5.0.0",
|
|
159
|
+
vitest: "^2.1.0"
|
|
160
|
+
}
|
|
161
|
+
};
|
|
162
|
+
|
|
163
|
+
// src/ui/banner.ts
|
|
164
|
+
var VERSION = package_default.version;
|
|
110
165
|
function showIntro() {
|
|
111
166
|
console.log("");
|
|
112
167
|
console.log(` ${import_picocolors.default.bold(import_picocolors.default.cyan("codeam"))} ${import_picocolors.default.dim(`v${VERSION}`)}`);
|
|
@@ -476,17 +531,23 @@ var ClaudeService = class {
|
|
|
476
531
|
process.exit(1);
|
|
477
532
|
}
|
|
478
533
|
const claudeCmd = findInPath("claude") ? "claude" : "claude-code";
|
|
534
|
+
const shell = process.env.SHELL || "/bin/sh";
|
|
479
535
|
try {
|
|
480
|
-
this.proc = pty.spawn(
|
|
536
|
+
this.proc = pty.spawn(shell, ["-c", `exec ${claudeCmd}`], {
|
|
481
537
|
name: "xterm-256color",
|
|
482
538
|
cols: process.stdout.columns || 80,
|
|
483
539
|
rows: process.stdout.rows || 24,
|
|
484
540
|
cwd: this.opts.cwd,
|
|
485
541
|
env: process.env
|
|
486
542
|
});
|
|
487
|
-
} catch {
|
|
543
|
+
} catch (err) {
|
|
544
|
+
const msg = err instanceof Error ? err.message : String(err);
|
|
488
545
|
console.error(
|
|
489
|
-
|
|
546
|
+
`
|
|
547
|
+
\u2717 Failed to launch Claude Code: ${msg}
|
|
548
|
+
Make sure claude is correctly installed: npm install -g @anthropic-ai/claude-code
|
|
549
|
+
If the issue persists, try: npm rebuild node-pty
|
|
550
|
+
`
|
|
490
551
|
);
|
|
491
552
|
process.exit(1);
|
|
492
553
|
}
|