You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
repo root: 75 tracked symlinks, most are tab-completion stubs that run a full rebuild when typed #12668
The repo root tracks 75 symlinks (git ls-files -s mode 120000, no path separator). Many are tab-completion prefix stubs of lib/*.sh helpers, so ./a, ./f, ./r or ./s silently run a host rebuild.
Evidence (HEAD, verified with git cat-file -p HEAD:<name>):
a, au, aut, f, fu, ful, r, re, reb, rebu, rebui, rebuil → ./lib/auth-rebuild-full.sh
o, of, off, offl, offli, offlin → ./lib/auth-rebuild-offline.sh
lib/auth-rebuild-full.sh:2 is ./lib/auth.sh ./lib/rebuild-full.sh, so invoking the stub runs the full rebuild path. offl, offli, offlin, rebu, rebui, rebuil, simp, simpl and nvi have zero textual references anywhere in the tree. The real entry points (rebuild, full, offline, simple, nvim) are referenced, for example in comments at nixos/environment/default.nix:18 and :45.
Related but distinct: #12137 (one root scratch symlink with a missing target) and #12136 (stale slice-1 status files).
Why it matters
Risk: a mistyped one-letter command at the repo root runs a full NixOS rebuild with no confirmation. The stub names give no signal of what they run.
Cost: 75 root entries bury the real layout, and make the root listing noisy for humans and agents.
Suggested fix shape
Confirm with git grep which stub names are used by anyone (scripts, docs, shell history notes).
Delete the stubs with no references. Keep the documented entry points.
Add a guard (or a note in the root README) so new root symlinks need a reason.
Claim-check (live, just now): issue OPEN, no assignees, no claims in comments, no open PR referencing #12668. Shortlist entry consumed via fleet agent shortlist take.
Plan, following the issue's suggested fix shape:
Enumerate all root symlinks (mode 120000, no path separator) at HEAD and git grep each stub name for real references (scripts, docs, notes).
Delete the stubs with no references; keep the documented entry points (rebuild, full, offline, simple, nvim, and any name with a real reference).
Add the root-README note so new root symlinks need a stated reason (the issue's narrower guard option).
Branch: xaltha/12668-symlink-rebuilds (pushed empty first, per house rules). Verification will be static + structural (stub targets resolve to the rebuild path before; stub paths gone and entry points intact after) — the stubs will not be executed, since executing one is exactly the hazard the issue files.
Remedy chosen: the issue's fix shape with its narrower guard option — delete unreferenced stubs + root README note, no new guard script.
Evidence:
Reference check: git grep for ./<name> invocations and alias definitions across the tree — all 28 deleted names (a au aut f fu ful r re reb rebu rebui rebuil o of off offl offli offlin si sim simp simpl n nv nvi v vi ss) have zero invocation references; single-letter alias-shaped hits are shell variables, ./a hits are URI docs/test fixtures.
Before: root symlinks 75; ./a → ./lib/auth-rebuild-full.sh → ./lib/auth.sh ./lib/rebuild-full.sh (hazard chain confirmed at HEAD, not executed).
After: root symlinks 47; all deleted paths absent; every kept entry point resolves to an existing target; post-deletion whole-word grep for the distinctive deleted names finds only the README removal note itself.
Exception found by the grep, kept deliberately:./s is load-bearing — the switch recipe in root.just runs ./s (and the generated just-recipes.json snapshots carry it). Kept alongside the documented entry points (rebuild, rebuild-simple, rebuild-offline, full, offline, simple, nvim, script).
Guard: "Root symlinks" section added to README.md (entry points + stated-reason rule); CLAUDE.md example list updated to surviving aliases (it had named n and v).
Housekeeping note: fleet agent shortlist take pops the top entry rather than a named one, so it consumed #12788's entry instead of this issue's; re-adding #12788 was refused by the tool ("handed out in the last two hours"), so #12788 will resurface via the next refill. This issue's entry was verified in the list before starting.
Activity
developing-today commentedon Nov 22, 2026
CODE-4657
dezren39 commentedon Nov 22, 2026
Refs #12664 (suggestions pass, dispatch #21076): this is one of four findings filed from that pass.
dezren39 commentedon Nov 23, 2026
Pickup — xaltha taking #12668.
Claim-check (live, just now): issue OPEN, no assignees, no claims in comments, no open PR referencing #12668. Shortlist entry consumed via
fleet agent shortlist take.Plan, following the issue's suggested fix shape:
git grepeach stub name for real references (scripts, docs, notes).rebuild,full,offline,simple,nvim, and any name with a real reference).Branch:
xaltha/12668-symlink-rebuilds(pushed empty first, per house rules). Verification will be static + structural (stub targets resolve to the rebuild path before; stub paths gone and entry points intact after) — the stubs will not be executed, since executing one is exactly the hazard the issue files.dezren39 commentedon Nov 23, 2026
Progress — slice landed as PR #13041 (OPEN, MERGEABLE, 30 files: 28 symlink deletions + README.md + CLAUDE.md). Says
Closes #12668.Remedy chosen: the issue's fix shape with its narrower guard option — delete unreferenced stubs + root README note, no new guard script.
Evidence:
git grepfor./<name>invocations and alias definitions across the tree — all 28 deleted names (a au aut f fu ful r re reb rebu rebui rebuil o of off offl offli offlin si sim simp simpl n nv nvi v vi ss) have zero invocation references; single-letter alias-shaped hits are shell variables,./ahits are URI docs/test fixtures../a→./lib/auth-rebuild-full.sh→./lib/auth.sh ./lib/rebuild-full.sh(hazard chain confirmed at HEAD, not executed)../sis load-bearing — theswitchrecipe inroot.justruns./s(and the generatedjust-recipes.jsonsnapshots carry it). Kept alongside the documented entry points (rebuild,rebuild-simple,rebuild-offline,full,offline,simple,nvim,script).README.md(entry points + stated-reason rule);CLAUDE.mdexample list updated to surviving aliases (it had namednandv).Housekeeping note:
fleet agent shortlist takepops the top entry rather than a named one, so it consumed #12788's entry instead of this issue's; re-adding #12788 was refused by the tool ("handed out in the last two hours"), so #12788 will resurface via the next refill. This issue's entry was verified in the list before starting.