@foxden-app/foxclaw 0.3.6 → 0.3.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 CHANGED
@@ -40,7 +40,7 @@ FoxClaw(狸爪)的目标很直接:让你用手机控制本机的 Codex,
40
40
  - Git、Node、`.env` 都玩得转?直接往下看快速设置。
41
41
  - 卡住了?看 [故障排查](./docs/zh/troubleshooting.md)。
42
42
 
43
- 最低要求:一个 Telegram bot token、你的 Telegram 数字用户 ID、Node.js 24、一份已登录的 `codex` CLI。首次安装大约 10–20 分钟。
43
+ 最低要求:一个 Telegram bot token、你的 Telegram 数字用户 ID、Node.js 24+、一份已登录的 `codex` CLI。首次安装大约 10–20 分钟。
44
44
 
45
45
  **30 秒体验**:启动 FoxClaw 后,给你的 Telegram 机器人发一句 `List files in DEFAULT_CWD`。Codex 会在本地检查那个目录,然后把结果发回 Telegram。
46
46
 
package/README_EN.md CHANGED
@@ -40,7 +40,7 @@ FoxClaw is more than message forwarding. It provides Telegram panels for Codex w
40
40
  - Already comfortable with Git, Node, and `.env` files? Use the quick setup below.
41
41
  - Something failed? Check [Troubleshooting](./docs/troubleshooting.md).
42
42
 
43
- The minimum install needs only a Telegram bot token, your numeric Telegram user id, Node.js 24, and a logged-in `codex` CLI. A first install usually takes 10–20 minutes.
43
+ The minimum install needs only a Telegram bot token, your numeric Telegram user id, Node.js 24+, and a logged-in `codex` CLI. A first install usually takes 10–20 minutes.
44
44
 
45
45
  **30-second demo**: after FoxClaw is running, send `List files in DEFAULT_CWD` to your Telegram bot. FoxClaw asks local Codex to inspect that folder on your computer and sends the answer back to Telegram.
46
46
 
@@ -39,7 +39,7 @@ DEFAULT_CWD=<paste absolute working directory here>
39
39
 
40
40
  Tasks:
41
41
  1. Inspect the machine first. If a FoxClaw service already exists, report it before changing services.
42
- 2. Ensure Node.js 24+ is available. If not, install or activate Node 24 with nvm.
42
+ 2. Ensure Node.js 24+ is available. If not, install or activate Node 24+ by any suitable method; nvm is only one common option.
43
43
  3. Ensure the Codex CLI exists and is logged in. If login is required, stop and tell me exactly what I need to do.
44
44
  4. Install or update FoxClaw with npm install -g @foxden-app/foxclaw@latest.
45
45
  5. Run foxclaw init, then write ~/.foxclaw/.env. Never print or commit the bot token.
@@ -25,17 +25,17 @@ You need:
25
25
 
26
26
  Use private chat first. Group and topic setup can wait until the bot replies reliably.
27
27
 
28
- ## 2. Install Node.js 24
28
+ ## 2. Install Node.js 24+
29
29
 
30
- FoxClaw needs Node.js 24 because it uses the built-in SQLite runtime.
30
+ FoxClaw needs Node.js 24+ because it uses the built-in SQLite runtime. It does not require nvm; you can use nvm, fnm, asdf, mise, Volta, Homebrew, or your system package manager.
31
31
 
32
- If you already have Node 24, this should print `v24...`:
32
+ If you already have Node 24+, this should print `v24...` or newer:
33
33
 
34
34
  ```bash
35
35
  node -v
36
36
  ```
37
37
 
38
- If not, install Node 24 with `nvm`:
38
+ If not, nvm is a good default for first-time users. Example:
39
39
 
40
40
  ```bash
41
41
  curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.3/install.sh | bash
@@ -47,7 +47,7 @@ node -v
47
47
  npm -v
48
48
  ```
49
49
 
50
- If `node -v` still shows an old version, close the terminal, open a new one, and run:
50
+ If you use nvm and `node -v` still shows an old version, close the terminal, open a new one, and run:
51
51
 
52
52
  ```bash
53
53
  nvm use 24
@@ -18,7 +18,7 @@ journalctl --user -u foxclaw.service -f
18
18
 
19
19
  | Symptom | Meaning | Fix |
20
20
  | --- | --- | --- |
21
- | `[FAIL] node >= 24` | Your current shell is using an older Node.js. | Run `nvm install 24 && nvm use 24`, then rerun `foxclaw doctor`. If the service uses old Node, reinstall it from a Node 24 shell with `foxclaw start`. |
21
+ | `[FAIL] node >= 24` | Your current shell is using an older Node.js. | Install or activate Node.js 24+ by any method, then rerun `foxclaw doctor`. If the service uses old Node, reinstall it from a Node 24+ shell with `foxclaw start`. |
22
22
  | `[FAIL] codex cli available` | The `codex` command is not in PATH. | Install Codex CLI or fix PATH, then confirm `codex --version` works. |
23
23
  | `[FAIL] telegram bot token configured` | `TG_BOT_TOKEN` is missing from `.env`. | Copy the token from `@BotFather` into `.env`. |
24
24
  | `[FAIL] telegram allowed user configured` | `TG_ALLOWED_USER_ID` is missing from `.env`. | Get your numeric id from `@userinfobot` and add it to `.env`. |
@@ -26,7 +26,7 @@ journalctl --user -u foxclaw.service -f
26
26
 
27
27
  ## Node Or npm Is Missing
28
28
 
29
- If you see `node: command not found` or `npm: command not found`, install Node.js 24 with `nvm`:
29
+ If you see `node: command not found` or `npm: command not found`, install Node.js 24+ using your preferred tool, such as nvm, fnm, asdf, mise, Volta, Homebrew, or your system package manager. This is an nvm example:
30
30
 
31
31
  ```bash
32
32
  curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.3/install.sh | bash
@@ -38,7 +38,7 @@ node -v
38
38
  npm -v
39
39
  ```
40
40
 
41
- If it still fails, close the terminal, open a new one, and run:
41
+ If you use nvm and it still fails, close the terminal, open a new one, and run:
42
42
 
43
43
  ```bash
44
44
  nvm use 24
@@ -48,7 +48,7 @@ nvm use 24
48
48
 
49
49
  If `npm install -g @openai/codex` fails with `EACCES`, `EPERM`, or `permission denied`, your global npm directory is not writable by your user.
50
50
 
51
- Recommended fix: use Node through `nvm`, then install again:
51
+ Recommended fix: use a user-level Node.js 24+ install, then install again. This is an nvm example:
52
52
 
53
53
  ```bash
54
54
  nvm install 24
@@ -56,7 +56,7 @@ nvm use 24
56
56
  npm install -g @openai/codex
57
57
  ```
58
58
 
59
- Avoid `sudo npm install -g ...` unless you already understand how your Node installation is managed. Mixing `sudo`, system Node, and `nvm` is a common source of broken PATHs.
59
+ Avoid `sudo npm install -g ...` unless you already understand how your Node installation is managed. Mixing `sudo`, system Node, and user-level Node managers is a common source of broken PATHs.
60
60
 
61
61
  If `codex` installs but FoxClaw still cannot find it, locate the binary:
62
62
 
@@ -211,9 +211,9 @@ foxclaw restart
211
211
 
212
212
  ## Service Starts With The Wrong Node Version
213
213
 
214
- The systemd installer records the absolute path of the Node process that is currently running FoxClaw. It does not rely on systemd loading `nvm.sh`. If you manage multiple Node versions with nvm, run `foxclaw start` from a Node 24 shell and the service will keep using that Node 24 path.
214
+ The systemd installer records the absolute path of the Node process that is currently running FoxClaw. It does not rely on systemd loading `nvm.sh` or any other shell init script. Whether you use nvm, fnm, asdf, mise, Volta, Homebrew, or system Node, run `foxclaw start` from a Node 24+ shell and the service will keep using that Node 24+ path.
215
215
 
216
- If you installed the service from a shell using Node 22 or older, reinstall it from a Node 24 shell:
216
+ If you installed the service from a shell using Node 22 or older, reinstall it from a Node 24+ shell. Example for nvm users:
217
217
 
218
218
  ```bash
219
219
  nvm use 24
@@ -221,7 +221,7 @@ foxclaw start
221
221
  systemctl --user status foxclaw.service
222
222
  ```
223
223
 
224
- The status output should show a Node 24 path in `ExecStart`. `foxclaw doctor` also checks the installed service Node path and warns if it is missing or older than 24.
224
+ The status output should show a Node 24+ path in `ExecStart`. `foxclaw doctor` also checks the installed service Node path and warns if it is missing or older than 24.
225
225
 
226
226
  ## Does It Run After Reboot?
227
227
 
@@ -16,15 +16,15 @@ Your code, shell access, Codex auth, and runtime state stay on the host machine.
16
16
 
17
17
  ## 1. Full Setup
18
18
 
19
- ### 1.1 Install Node.js 24
19
+ ### 1.1 Install Node.js 24+
20
20
 
21
- FoxClaw requires Node.js 24. Check first:
21
+ FoxClaw requires Node.js 24+ and does not require nvm. Check first:
22
22
 
23
23
  ```bash
24
24
  node -v
25
25
  ```
26
26
 
27
- If this is not `v24...`, install Node 24 with `nvm`:
27
+ If this is not `v24...` or newer, install Node 24+ with nvm, fnm, asdf, mise, Volta, Homebrew, or your system package manager. This is an nvm example:
28
28
 
29
29
  ```bash
30
30
  curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.3/install.sh | bash
@@ -38,7 +38,7 @@ DEFAULT_CWD=<把绝对工作目录粘贴在这里>
38
38
 
39
39
  任务:
40
40
  1. 先检查机器环境。如果已经存在 FoxClaw 服务,先报告再改服务。
41
- 2. 确保 Node.js 24+ 可用;如果没有,请用 nvm 安装或切到 Node 24
41
+ 2. 确保 Node.js 24+ 可用;如果没有,请用任意合适方式安装或切到 Node 24+,nvm 只是常见选择。
42
42
  3. 确保 Codex CLI 存在并且已经登录。如果需要登录,停下来告诉我具体要执行什么。
43
43
  4. 用 npm install -g @foxden-app/foxclaw@latest 安装或升级 FoxClaw。
44
44
  5. 运行 foxclaw init,然后写入 ~/.foxclaw/.env。不要打印或提交 bot token。
@@ -5,7 +5,7 @@
5
5
  ## 适合什么时候用
6
6
 
7
7
  - 你想让 Codex 通过 SSH 帮另一台 Mac 安装 FoxClaw。
8
- - 你希望 agent 先检查环境,再决定如何安装 Node.js 24Codex CLI 和 FoxClaw。
8
+ - 你希望 agent 先检查环境,再决定如何安装 Node.js 24+、Codex CLI 和 FoxClaw。
9
9
  - 你不想手动复制每一步安装命令,但愿意提供 Telegram bot token、用户 ID 和默认工作目录。
10
10
 
11
11
  ## 基本流程
@@ -23,17 +23,17 @@ FoxClaw 跑在你的电脑上。手机发消息给 Telegram bot,bot 把消息
23
23
  - 一个 Codex 可以工作的目录,例如 `~/Projects` 或 `~/Desktop`
24
24
  - 第一次安装大约 10-20 分钟
25
25
 
26
- ## 2. 安装 Node.js 24
26
+ ## 2. 安装 Node.js 24+
27
27
 
28
- FoxClaw 需要 Node.js 24,因为它使用 Node 内置 SQLite 运行时。
28
+ FoxClaw 需要 Node.js 24+,因为它使用 Node 内置 SQLite 运行时。不强依赖 nvm;你可以用 nvm、fnm、asdf、mise、Volta、Homebrew 或系统包管理器安装。
29
29
 
30
- 如果已经安装 Node 24,这条命令会输出 `v24...`:
30
+ 如果已经安装 Node 24+,这条命令会输出 `v24...` 或更高版本:
31
31
 
32
32
  ```bash
33
33
  node -v
34
34
  ```
35
35
 
36
- 如果不是 Node 24,推荐用 `nvm` 安装:
36
+ 如果不是 Node 24+,推荐普通用户用 `nvm` 安装,示例:
37
37
 
38
38
  ```bash
39
39
  curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.3/install.sh | bash
@@ -45,7 +45,7 @@ node -v
45
45
  npm -v
46
46
  ```
47
47
 
48
- 如果 `node -v` 仍然显示旧版本,关闭终端,重新打开后运行:
48
+ 如果使用 nvm 后 `node -v` 仍然显示旧版本,关闭终端,重新打开后运行:
49
49
 
50
50
  ```bash
51
51
  nvm use 24
@@ -18,7 +18,7 @@ journalctl --user -u foxclaw.service -f
18
18
 
19
19
  | 现象 | 含义 | 处理方式 |
20
20
  | --- | --- | --- |
21
- | `[FAIL] node >= 24` | 当前 shell 使用的是旧版 Node.js。 | 运行 `nvm install 24 && nvm use 24`,再重新执行 `foxclaw doctor`。如果服务仍用旧 Node,从 Node 24 的 shell 里重新执行 `foxclaw start`。 |
21
+ | `[FAIL] node >= 24` | 当前 shell 使用的是旧版 Node.js。 | 先用任意方式安装或切换到 Node.js 24+,再重新执行 `foxclaw doctor`。如果服务仍用旧 Node,从 Node 24+ 的 shell 里重新执行 `foxclaw start`。 |
22
22
  | `[FAIL] codex cli available` | `codex` 命令不在 PATH 里。 | 安装 Codex CLI 或修正 PATH,再确认 `codex --version` 可用。 |
23
23
  | `[FAIL] telegram bot token configured` | `.env` 里缺少 `TG_BOT_TOKEN`。 | 从 `@BotFather` 复制 token,填入 `.env`。 |
24
24
  | `[FAIL] telegram allowed user configured` | `.env` 里缺少 `TG_ALLOWED_USER_ID`。 | 从 `@userinfobot` 获取数字 ID,填入 `.env`。 |
@@ -26,7 +26,7 @@ journalctl --user -u foxclaw.service -f
26
26
 
27
27
  ## Node 或 npm 不存在
28
28
 
29
- 如果看到 `node: command not found` 或 `npm: command not found`,用 `nvm` 安装 Node.js 24
29
+ 如果看到 `node: command not found` 或 `npm: command not found`,先用你习惯的方式安装 Node.js 24+,例如 nvm、fnm、asdf、mise、Volta、Homebrew 或系统包管理器。下面是 nvm 示例:
30
30
 
31
31
  ```bash
32
32
  curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.3/install.sh | bash
@@ -38,7 +38,7 @@ node -v
38
38
  npm -v
39
39
  ```
40
40
 
41
- 如果仍然失败,关闭终端,重新打开后运行:
41
+ 如果使用 nvm 后仍然失败,关闭终端,重新打开后运行:
42
42
 
43
43
  ```bash
44
44
  nvm use 24
@@ -48,7 +48,7 @@ nvm use 24
48
48
 
49
49
  如果 `npm install -g @openai/codex` 或 `npm install -g @foxden-app/foxclaw` 报 `EACCES`、`EPERM`、`permission denied`,说明当前全局 npm 目录不可写。
50
50
 
51
- 推荐处理方式是通过 `nvm` 使用用户级 Node,然后重新安装:
51
+ 推荐处理方式是使用一个用户级 Node.js 24+,然后重新安装。下面是 nvm 示例:
52
52
 
53
53
  ```bash
54
54
  nvm install 24
@@ -57,7 +57,7 @@ npm install -g @openai/codex
57
57
  npm install -g @foxden-app/foxclaw
58
58
  ```
59
59
 
60
- 除非你很清楚本机 Node 的安装方式,否则不要直接混用 `sudo npm install -g ...`。`sudo`、系统 Node `nvm` 混在一起,常见结果是 PATH 断掉或服务启动时找不到命令。
60
+ 除非你很清楚本机 Node 的安装方式,否则不要直接混用 `sudo npm install -g ...`。`sudo`、系统 Node 和用户级 Node 管理器混在一起,常见结果是 PATH 断掉或服务启动时找不到命令。
61
61
 
62
62
  如果 `codex` 已安装但 FoxClaw 找不到它,先定位二进制:
63
63
 
@@ -212,9 +212,9 @@ foxclaw restart
212
212
 
213
213
  ## 服务用了错误的 Node 版本
214
214
 
215
- systemd 安装脚本会记录当时正在运行的 Node 绝对路径,不依赖 systemd 去加载 `nvm.sh`。如果你用 nvm 管多个 Node 版本,原则是:从 Node 24 的 shell 里执行 `foxclaw start`,服务之后就固定使用这个 Node 24 路径。
215
+ systemd 安装脚本会记录当时正在运行的 Node 绝对路径,不依赖 systemd 去加载 `nvm.sh` 或其它 shell 初始化脚本。无论你用 nvm、fnm、asdf、mise、Volta、Homebrew 还是系统 Node,原则都是:从 Node 24+ 的 shell 里执行 `foxclaw start`,服务之后就固定使用这个 Node 24+ 路径。
216
216
 
217
- 如果你从 Node 22 或更旧版本的 shell 里安装过服务,请从 Node 24 的 shell 重新安装:
217
+ 如果你从 Node 22 或更旧版本的 shell 里安装过服务,请从 Node 24+ 的 shell 重新安装。nvm 用户示例:
218
218
 
219
219
  ```bash
220
220
  nvm use 24
@@ -222,7 +222,7 @@ foxclaw start
222
222
  systemctl --user status foxclaw.service
223
223
  ```
224
224
 
225
- 状态输出里应该能看到 Node 24 的路径。`foxclaw doctor` 也会检查已安装服务里的 Node 路径,如果发现路径不存在或版本低于 24,会提示重新运行 `foxclaw start`。
225
+ 状态输出里应该能看到 Node 24+ 的路径。`foxclaw doctor` 也会检查已安装服务里的 Node 路径,如果发现路径不存在或版本低于 24,会提示重新运行 `foxclaw start`。
226
226
 
227
227
  ## 重启后是否会自动运行
228
228
 
@@ -16,15 +16,15 @@ FoxClaw 把本机 Codex 包成一个可从手机控制的服务。Telegram 或
16
16
 
17
17
  ## 1. 完整安装流程
18
18
 
19
- ### 1.1 安装 Node.js 24
19
+ ### 1.1 安装 Node.js 24+
20
20
 
21
- FoxClaw 需要 Node.js 24。先检查:
21
+ FoxClaw 需要 Node.js 24+,不强依赖 nvm。先检查:
22
22
 
23
23
  ```bash
24
24
  node -v
25
25
  ```
26
26
 
27
- 如果不是 `v24...`,推荐用 `nvm`:
27
+ 如果不是 `v24...` 或更高版本,可以用 nvm、fnm、asdf、mise、Volta、Homebrew 或系统包管理器安装 Node 24+。下面是 nvm 示例:
28
28
 
29
29
  ```bash
30
30
  curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.3/install.sh | bash
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@foxden-app/foxclaw",
3
- "version": "0.3.6",
3
+ "version": "0.3.7",
4
4
  "description": "Foxden local execution claw for controlling Codex from trusted chat interfaces.",
5
5
  "type": "module",
6
6
  "main": "dist/main.js",