📝 docs(agent_rules): allow plan execution on current branch

This commit is contained in:
csh 2026-05-20 15:49:40 +08:00
parent 16c7230c03
commit 98c3f305f9
1 changed files with 11 additions and 0 deletions

View File

@ -188,6 +188,17 @@ python {{PLAYBOOK_SCRIPTS}}/main_loop.py finish \
-note "<原因>" -note "<原因>"
``` ```
### Plan 场景下的分支与隔离策略
- 本节仅适用于通过主循环领取并执行 Plan 的场景
- 默认允许在当前分支直接执行 Plan包括 `main` / `master`
- 不强制为 Plan 执行创建隔离工作区、临时分支或 `git worktree`
- 仅在以下场景使用隔离工作区:
- 用户明确要求隔离执行
- Plan 文本自身明确要求隔离执行
- 当前任务需要并行隔离以避免相互影响
- 如外部技能、工具或默认流程要求先隔离,再执行 Plan以本文件和用户当前指令为准
### 执行规则 ### 执行规则
1. 先 `claim`,拿到 `PLAN=` 后再读取 Plan 内容 1. 先 `claim`,拿到 `PLAN=` 后再读取 Plan 内容