Legacy cleanup — 2026¶
This document records the directories removed from the repository
during the v0.0.3 P0 work and explains why each one is gone. Future
contributors who notice an old reference can use this as the
canonical source of truth for “where did tui/ go?”.
Summary¶
The C++23 rewrite produced a small archipelago of stranded
directories — some from the pre-rewrite Python tree, some from local
tool caches that crept into a tracked path before .gitignore caught
up. None of them had any tracked files at the time of this commit,
so the cleanup is metadata-only: .gitignore is updated to make the
directories permanently invisible to git, and contributors are asked
to delete the on-disk leftovers via ./.git/cleanup-stale-dirs.sh.
Directories removed¶
Path |
What it was |
Replacement |
|---|---|---|
|
Python |
|
|
Local Python virtualenv used while the project was Python-first |
None — the C++23 binary is the only runtime now. Contributors who still want Python tooling for ancillary scripts should keep their venv outside the repo (e.g. |
|
Separate virtualenv from the abandoned voice-interface experiment |
None — |
|
Pre-rewrite hand-rolled Python |
|
|
CPython bytecode cache from the above |
n/a |
|
Empty placeholder from the pre-rewrite layout |
|
|
Empty placeholder for the agent-bus prototype |
|
|
Empty placeholder for a packaging-output directory |
|
|
Empty placeholder |
|
|
Stale directory from an aborted vendor experiment |
None. |
|
Local pytest tool cache |
n/a — moved to a |
What this commit changes¶
Adds the directories above to the top-level
.gitignoreso they cannot be re-introduced into the tracked tree.Adds a global
__pycache__/+*.pycrule so transient Python build artefacts never appear again, regardless of where they land.Records this rationale at
docs/architecture/legacy-cleanup-2026.md.
What this commit does NOT change¶
The on-disk directories are not deleted by this commit because none of them were tracked in the first place — there is nothing for git to remove. To clear them from your working tree, dry-run first:
for d in tui .venv .venv-voice bin metrics bus packages prompts codex .pytest_cache; do
if [ -e "$d" ]; then
tracked=$(git ls-files "$d" 2>/dev/null | wc -l | tr -d ' ')
bytes=$(du -sk "$d" 2>/dev/null | awk '{print $1}')
printf " %-18s tracked=%s, %s KB\n" "$d" "$tracked" "$bytes"
fi
done
Then, once you have eyes on the inventory, remove only the directories you have no local use for:
# Example — pick the subset that applies to your checkout.
rm -rf tui bus packages prompts codex bin/__pycache__ \
.pytest_cache .venv-voice
The Python virtualenvs (.venv, .venv-voice) might still be in
local use for ancillary tooling against the C++23 build, so they’re
listed separately above — review them before deleting.
Why split tracking from on-disk deletion¶
A bulk shell script that rm -rfs anonymous directories is exactly
the kind of action that wants a human in the loop. Treating the
deletion as a separate, eyes-on step lets each contributor:
Review the list against their own checkout.
Skip directories they want to keep locally.
Run the cleanup once and never again.
A future CI step (planned with P0.12 — architecture-quality
workflow repair) will assert that the
directories listed here are never re-added to a tracked path, so
that even if a stray tui/ appears in someone’s working tree, it
cannot land in a PR.