clawt 2.18.0 → 2.20.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.
- package/README.md +12 -2
- package/dist/index.js +500 -102
- package/dist/postinstall.js +31 -0
- package/docs/spec.md +171 -4
- package/package.json +1 -1
- package/src/commands/projects.ts +324 -0
- package/src/commands/resume.ts +8 -2
- package/src/constants/index.ts +1 -1
- package/src/constants/messages/index.ts +2 -0
- package/src/constants/messages/projects.ts +25 -0
- package/src/constants/prompt.ts +28 -0
- package/src/index.ts +2 -0
- package/src/types/command.ts +8 -0
- package/src/types/index.ts +2 -1
- package/src/types/project.ts +45 -0
- package/src/utils/formatter.ts +46 -0
- package/src/utils/fs.ts +32 -1
- package/src/utils/index.ts +3 -3
- package/src/utils/worktree-matcher.ts +268 -1
- package/tests/unit/commands/resume.test.ts +29 -8
- package/tests/unit/utils/formatter.test.ts +91 -1
- package/tests/unit/utils/fs.test.ts +125 -2
- package/tests/unit/utils/worktree-matcher.test.ts +142 -1
package/README.md
CHANGED
|
@@ -100,10 +100,10 @@ clawt run -b <branch> --tasks "任务1" --tasks "任务2" --dry-run
|
|
|
100
100
|
|
|
101
101
|
```bash
|
|
102
102
|
clawt resume -b <branch> # 指定分支
|
|
103
|
-
clawt resume #
|
|
103
|
+
clawt resume # 交互式多选(按创建日期分组)
|
|
104
104
|
```
|
|
105
105
|
|
|
106
|
-
|
|
106
|
+
不传 `-b` 时,分支列表按创建日期分组显示,支持全局全选和按组全选。选 1 个在当前终端恢复,选多个自动在独立终端 Tab 中批量恢复(仅 macOS)。
|
|
107
107
|
|
|
108
108
|
如果目标 worktree 存在历史会话,会自动继续上次对话(`--continue`)。
|
|
109
109
|
|
|
@@ -214,6 +214,16 @@ clawt status --json # JSON 格式
|
|
|
214
214
|
clawt reset
|
|
215
215
|
```
|
|
216
216
|
|
|
217
|
+
### `clawt projects` — 跨项目 worktree 概览
|
|
218
|
+
|
|
219
|
+
```bash
|
|
220
|
+
clawt projects # 查看所有项目概览
|
|
221
|
+
clawt projects my-project # 查看指定项目的 worktree 详情
|
|
222
|
+
clawt projects --json # JSON 格式输出
|
|
223
|
+
```
|
|
224
|
+
|
|
225
|
+
展示所有项目的 worktree 数量、磁盘占用和最近活跃时间,或查看指定项目下每个 worktree 的详细信息。
|
|
226
|
+
|
|
217
227
|
### `clawt config` — 交互式查看和修改配置
|
|
218
228
|
|
|
219
229
|
```bash
|