fix: Git Workflow 多 Session 并发隔离改造 - Closes #124
CI / test (pull_request) Successful in 22s

核心变更:
- _common.sh: setup_worktree 改为 session-unique detached worktree (origin/main)
- 所有 Agent 文档移除 git checkout main / git pull origin main
- Feature branch 统一从 origin/main 创建: git fetch origin && git checkout -b <branch> origin/main
- CLAUDE.md: 新增工作区隔离章节, primary worktree 定义为只读参考区
- 新增 start_generic.sh: Generic session worktree 隔离启动器

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
2026-06-08 16:11:32 +08:00
parent 9629eb6ae0
commit e4f0b77ca8
9 changed files with 80 additions and 66 deletions
+2 -4
View File
@@ -19,15 +19,13 @@ source "$SCRIPT_DIR/_common.sh"
setup_worktree "$GITEA_USER"
# Cleanup worktree on exit (optional, comment out to keep for debugging)
trap 'cleanup_worktree "$GITEA_USER"' EXIT
trap 'cleanup_worktree' EXIT
banner "QE"
require_token
AGENT_CONF="$_MAIN_REPO_DIR/.claude/agents/qe-agent.md"
launch_agent \
"qe-agent" \
"$AGENT_CONF" \
"$PROJECT_DIR/.claude/agents/qe-agent.md" \
"QE-Agent" \
"执行一次 Issue 巡检(单次任务,不要用 /loop):
1. python scripts/agent_poller.py --action list --labels test-code 检查 test-code Issue