clone
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseClone the current conversation so the user can branch off and try a different approach.
Steps:
- Get the current session ID and project path:
tail -1 ~/.claude/history.jsonl | jq -r '[.sessionId, .project] | @tsv' - Find clone-conversation.sh with bash:
find ~/.claude -name "clone-conversation.sh" 2>/dev/null | sort -V | tail -1- This finds the script whether installed via plugin or manual symlink
- Uses version sort to prefer the latest version if multiple exist
- Run:
<script-path> <session-id> <project-path>- Always pass the project path from the history entry, not the current working directory
- Tell the user they can access the cloned conversation with and look for the one marked
claude -r(e.g.,[CLONED <timestamp>])[CLONED Jan 7 14:30]
克隆当前对话,以便用户可以分支尝试不同的方案。
步骤:
- 获取当前会话ID和项目路径:
tail -1 ~/.claude/history.jsonl | jq -r '[.sessionId, .project] | @tsv' - 使用bash查找clone-conversation.sh:
find ~/.claude -name "clone-conversation.sh" 2>/dev/null | sort -V | tail -1- 无论该脚本是通过插件安装还是手动软链接创建的,都可以被找到
- 如果存在多个版本,会通过版本排序优先选择最新版本
- 运行:
<script-path> <session-id> <project-path>- 始终传入历史记录条目中的项目路径,而非当前工作目录
- 告知用户可以通过访问克隆后的对话,寻找标记为
claude -r的条目即可(例如:[CLONED <timestamp>])[CLONED Jan 7 14:30]