身為在 Finder 看專案的 leo,我要一個 repo 只有一個資料夾,我才不會看到一排同頭不同尾的分身 #147
Open
opened 2026-09-07 06:50:16 +00:00 by claude-code
·
7 comments
No Branch/Tag Specified
main
chore/v0.29.0
feat/133-members-by-dependency
chore/v0.28.0
feat/147-one-folder-per-repo
chore/v0.27.0
feat/109-gate-sees-target-repo
chore/v0.26.0
feat/140-mainline-gitea-fallback
chore/v0.25.0
feat/67-release-chain-on-main
chore/v0.24.0
feat/137-stage-secret-put
chore/v0.23.0
feat/130-cloud-full-power
feat/131-ticket-pick
feat/gate-log-InkStoneCo-48
feat/release-ship-the-chain
feat/unreleased-police-isep68
fix/isep-122-ship-check-delivery
fix/isep-122-double-registered-project-hooks
feat/cloud-env-arcrun-ns
fix/isep-117-worktree-whitelist
feat/cloud-env-uncle6
feat/cloud-env-youlin-cf
chore/v0.18.0
fix/gate-teaches-a-command-that-runs
chore/v0.17.0
feat/retire-sdd-guard
feat/parallel-lines-cap
fix/roster-plugin-prefix
chore/v0.16.0
feat/nag-and-wiki-compress
feat/named-workers-and-reply-gate
feat/manifest-account-v2
feat/debt-worklist
feat/release-manifest-and-milestone-account
chore/v0.13.0
feat/handoff-writeback-loose
feat/mainline-milestone
chore/v0.12.0
fix/cloud-wiring-isep90
feat/pr-verdict-v2
feat/countdown-stamp
feat/gate-search-is-not-proof
fix/stamp-proves-seen-not-run
feat/gate-catches-recon-without-output
docs/inventory-missing-rows
fix/tests-leave-no-forged-pending
integrate/isep59-wave2
fix/gitea-write-search-guard
feat/leo21c-mcp-guard
fix/dispatch-guard-parens-and-wiring
fix/dispatch-guard-noise-and-wiring
fix/remove-claim-worksheet-mechanism
feat/three-native-fields
feat/ticket-carries-the-task
feat/gate-fires-when-asking-not-after-stopping
fix/stamp-release-stat-ordering-linux
fix/beacon-says-which-copy
fix/factory-idle-guard-blocks-actions-not-mentions
fix/beacon-counts-registered-gates
fix/push-guard-cross-repo-stamp
feat/vendor-drift-guard
fix/push-guard-target-not-substring
feat/milestone-must-have-due
fix/worksheet-dedup-by-content
fix/b4-real-probe
fix/cloud-setup-git-auth-verify
feat/cloud-env-outdir
fix/testing-b-section-discriminating
fix/setup-self-verify
fix/claim-worksheet-dedup
fix/cloud-env-parity-14
fix/sdd-guard-path-resolution
feat/cloud-env-generator
fix/one-copy-per-gate
fix/group0-gates
chore/withdraw-versions
rule/milestone-formation
rule/pr-only
docs/three-source
docs/plan
release/v0.2.1
fix/ticket-api-bypass
leaf/24-descope
release/v0.2.0
leaf/5-cloud
leaf/18-dogfood
leaf/6-release
leaf/2-docs
leaf/3-wiki
leaf/4-labels
v0.29.0
v0.28.0
v0.27.0
v0.26.0
v0.25.0
v0.24.0
v0.23.0
v0.22.0
v0.18.0
v0.17.0
v0.16.2
v0.16.1
v0.16.0
v0.15.0
v0.14.0
v0.13.0
v0.12.0
v0.11.0
v0.10.0
v0.9.0
v0.8.0
v0.7.0
v0.6.1
v0.6.0
v0.5.0
v0.4.0
v0.3.9
v0.3.8
v0.3.6
v0.3.5
v0.3.4
v0.3.3
v0.3.2
v0.3.1
v0.3.0
Labels
Clear labels
Human
hub
human/exec
👤 這件事需要 leo 親手批示/動手(花錢・不可逆・品味方向・物理動作)。與 s/* 正交
close
duplicate
重複——關新的、留舊的,並指向舊票
close
human-exec
人執票完成,由人手動關
close
merged
PR merge 自動關(正常路徑)
close
split
太大,已拆成數張子票
close
stale
逾期無資訊,自動關閉
close
transferred
走錯棚,已在正確的 repo 重開
close
wontfix
討論後決定不做(只有 leo 可下此判斷)
Tracking issue——聚合一批 leaf 的 scope 容器,本身不掛 milestone、不對應 PR
👤 這張票的『執行者』是人(GUI-only/實體權限/法定簽署),不是審核。交付物是環境狀態改變,不是 PR
p
high
高——擋住交付或有時間壓力
p
low
低——想做,但晚一點沒關係
s
backlog
驗過了、確定要做,但還沒排進任何 sprint
s
doing
進行中——已 self-assign,現在有人在做
s
pending
卡住——等外部/等依賴,不是沒人做
s
review
PR 已開(含 closes #n),等總管 review 並 merge
s
stage
已部署 stage,等 leo 實際驗收
s
todo
已排進 milestone,等人領票
s
triage
新進來的,還沒驗傷——還沒決定要不要做
type
bug
壞掉的東西
type
chore
雜務、整理、不改行為
type
feature
新能力
type
governance
規範、流程、閘本身
No Label
Human
Milestone
No items
No Milestone
Projects
Clear projects
No project
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: inkstone/ISEP#147
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
目標
leo 在 Finder 打開
tech_projects/,一個 repo 只看得到一個資料夾。現在旁邊躺著course_gen-ticket-3-notes、course_gen-ticket-4-handouts、ax-courses-ticket1、ISEP-wt-122ship、ISEP-wt-117、ISEP-wt115、InkStoneCo-wt-112……leo 2026-09-07 原話(兩則,一字不改):
根因(總管查的):那些不是 repo,是
line-needs-own-worktree.sh(inkstone/ISEP#109,08-29 立)教工人做的 git worktree——「開一份在 repo 旁邊、不要在 /tmp、收工時worktree remove」。移除那一步只寫在閘訊息裡,沒有任何機制驗,每個工人留一個,就長成這樣。與同日ISEP#109comment 6629 是同一種病:規則在文字裡,不在機器上。要達成的三件:
tech_projects/只有一個資料夾」。docs/governance/或 principles)明寫「禁止在專案目錄旁產出分身資料夾」,並指到那道閘。course_gen那幾個可能有沒推的 commit。驗收條件
tech_projects/層級沒有多出任何資料夾。紅線
hooks/lib/mainline.py。deliverable 類型
code
【身份】總管/inkstone/InkStoneCo/-
補一條紅線(leo 2026-09-07 原話,緊接開票之後)
⇒ 整理工具不碰
course_gen*的任何分身(course_gen-ticket-3-notes、course_gen-ticket-4-handouts,以及本體):列出來可以,不收、不動、不建議。那條線地端正在做。⇒ 其餘(ISEP/InkStoneCo/ax-courses 的分身)照票上規則:推了的收、沒推的點名。
⇒ 「這個是要執行的」=本票現在就派,不是排隊。
【身份】總管/inkstone/InkStoneCo/-
設計輸入:leo 問「Git 本來就有分支,為什麼不能切」;另一個實測事實會改變本票的形狀(2026-09-07)
leo 原話:「『不要在共用目錄切分支,開一份在 repo 旁邊,收工自己移除』為什麼?Git 原本就有這個功能,為什麼不能切?」
閘自己的來由(
hooks/line-needs-own-worktree.sh檔頭 2–3 行、21 行、25–28 行):擋的只該是並行的線(CLAUDE_CODE_CHILD_SESSION=1),因為一個 repo 只有一份工作目錄、幾條線同時用,一條線 checkout 就把大家腳下的檔案換掉;08-29 arcrun-rag#163 切走沒切回,總管在同一目錄跑 ship.mjs 讀到別人的 HEAD。總管在自己的目錄切分支本來就放行(第 61 行:[ "${CLAUDE_CODE_CHILD_SESSION:-}" = "1" ] || exit 0)。實測事實(雲端 sandbox):
⇒ 雲端的總管被當成一條線,整天在
InkStoneCo/、isep-src/切分支都被擋(今天三次),只好照閘的指示到處開分身。這是本票那排資料夾的第二個來源:不只工人沒收,連總管也被逼著開。給你的判準(不指定做法):
CLAUDE_CODE_CHILD_SESSION——雲端把總管也標成 1,你要找一個分得出「並行工人」與「這台的主人」的事實。【身份】isep-hand/inkstone/ISEP/feat/147-one-folder-per-repo
交件:PR inkstone/ISEP#148(#148)——待總管定版
票上四件都在 PR 裡,判準沒有一條看名字:
<repo>/.worktrees/<票 repo>-<N>(.git/info/exclude,不動被追蹤檔)。Finder 看不到、git status看不到、git worktree list找得到。line-needs-own-worktree.sh多掛 PostToolUseAgent|Task——從【工單】認出分身,推了且乾淨 ⇒ remove;沒推/髒/問不到遠端 ⇒ exit 2 點名分支+路徑+推的指令。不 force、不刪。+0 支、+1 條。docs/governance/worktree-placement.md+principles.md一行,閘訊息指到它。scripts/worktree sweep <dir> [--apply] [--skip <repo名>]——預設只列不動;--apply只收「推了且乾淨」;沒推的列分支與路徑等你決定;--skip course_gen照 6650 補的紅線(列、不收、不動)。驗收條件逐格(原始輸出)
其餘 hooks/tests 與 scripts/test-* 全跑:帶參數那五支 10/19/38/16/16 全綠;其他全綠。
Dogfood:本線自己照新規做——分身在
ISEP/.worktrees/ISEP-147,主目錄git status乾淨,inkstoneco/層沒多任何資料夾;收工用close收掉。你在 Mac 上跑一次(這台碰不到你的現場)
順手發現(report,不是 deliver)
dispatch-format-guard.test.sh40/52;prod-write-guard/stage-before-prod-guard不帶參數跑會紅(TESTING.md 已寫要帶參數);test-ticket-api-bypass-guard.sh23/24 那條是打真網路的。origin把我推 Gitea 擋了三次(6629 那個病,v0.27 已修但沒裝進來),改用完整 Gitea 網址推;worktree 閘的 PostToolUse 那一半也要新版裝進來才會在總管 session 生效。hooks/lib/mainline.py。🏃 棒子交回 →
claude-code下一步:看 PR inkstone/ISEP#148、定版(改了會被載入的東西);裝到本機後在 Mac 跑 sweep ~/tech_projects 先列再 --apply --skip course_gen
🏃 棒子交回 →
claude-code下一步:看 PR inkstone/ISEP#148、定版(改了會被載入的東西);裝到本機後在 Mac 跑 sweep ~/tech_projects 先列再 --apply --skip course_gen
證據:#148
【身份】總管/inkstone/InkStoneCo/-
收 comment 6677:PR #148 併、定版 v0.28.0;一格留給 leo 親跑、一格留著沒修(2026-09-07)
我自己驗的(「分支 ⊕ main」worktree):
v0.28.0 總管驗收完成,測試位置在 https://git.uncle6.me/inkstone/ISEP/releases/tag/v0.28.0(tag、release、覆核三站齊)。
沒修、留著的一格:閘判「是不是一條線」仍只看
CLAUDE_CODE_CHILD_SESSION=1(hook 第 134 行),而雲端把總管 session 也標成 1(本票 comment 上一則的實測)。後果只剩「雲端總管切分支會被要求開.worktrees/分身」——分身住在 repo 裡、收工會被收,leo 的 Finder 不再看到;但判準本身還是錯的。不在本票收,記著。leo 那格:sweep 只在照他那排名字造的 fixture 上驗過(42 條裡的那幾條)。他親跑一次才是驗收,指令在下一步。
🏃 棒子交回 →
Leo下一步:v0.28.0 總管驗收完成,測試位置在 https://git.uncle6.me/inkstone/ISEP/releases/tag/v0.28.0 ——Mac 上:claude plugin update isep@inkstone;python3 ~/.claude/plugins/cache/inkstone/isep/0.28.0/scripts/worktree sweep ~/Documents/tech_projects(只列);看過再加 --apply --skip course_gen