BEE-006: a submodule is an ordinary repo — install and index recurse into it

Now
OPEN
Sev
MED
Ask
gritzko
Rep
///bee
On1
BEE-001
See
BEE-002
See
LITE-044

index/index.js readTree DROPS gitlinks (mode 0o160000) — a submodule's blobs live in another ODB, so rows about them in the parent's lane could never be rebuilt by rm -rf .git/be there. Submodules are therefore invisible to bee today: html/ in the journal lists blank and its pages are unreachable. The ruling is uniformity, not a special case: bee install and bee index RECURSE into every initialised submodule, so a sub is an ordinary registered repo with its own lane and every link crossing the boundary is an ordinary cross-repo link (BEE-002).

Input

Context

BEE-001 made install the registration point ($HOME/.config/bee/repos, one absolute worktree path per line) and gave it the index + lindex bring-up; nothing walks into a submodule.

Goals

Installing or indexing a parent leaves every initialised submodule installed and indexed too, and no code anywhere carries a submodule case.

Constraints

WIP

Design decisions

  1. UNIFORMITY IS THE POINT: a submodule is registered, indexed and linked exactly like any other repo, so the only new code is the WALK, not a case.
  2. The parent-side exception is attribution only: a gitlink bump mints ONE REV-CMMT row on the submodule's path (LITE-044 dir-rev shape), never a REV-BLOB — a commit sha is no blob of the parent's.
  3. RULED (agent, 2026-08-15): bee index <parent> DOES recurse by default, because the N-gitdir fear is not the hot path — the views (list, log, diff, lindex, door) all ride bringUp on ONE open repo and never recurse, so only the explicit index verb and install walk subs, and a repo whose tip carries no .gitmodules pays one cached Map hit. index takes opts.subs === false for a caller that must not.
  4. The parent's ATTRIBUTION cannot ride descend: dog/git's GITTreeDiff drops gitlinks in C (git_td_next), so no diff ever hands one back. The gitlink revs are minted beside it, from the tip's sub paths compared over the commit's tree and its parents' — readTree's drop stands untouched.

TODOs

Blockers and bummers

Outcome

Landed in the worktree /home/gritzko/src/bee2, uncommitted.