chore: finish the .superset → .paradev move for repo config, dev data and worktree repair
Merged
SA
14d ago+302+302+012345678901234567890123456789-202-202-012345678901234567890123456789
Summary
- This repo's workspace config moves from
.superset/to.paradev/, and the per-worktree dev data foldersuperset-dev-data/becomesparadev-dev-data/. Neither keeps backwards compatibility in the scripts. - Fix: after the home move,
git worktree repairskipped worktrees whenever one stored workspace path had a deleted parent folder. Machines that already hit it (canary) now get repaired on their next boot: the repair runs on every boot, but only for checkouts whose git records still name~/.superset. - Fix: the agent-setup hook matcher now counts
~/.paradev/hooks/...as managed, so a dev build replaces the installed app's Cursor, Gemini and notify hooks again instead of adding its own next to them.
Why / Context
Part of removing "superset" from every surface. I audited the home move from #9158 on a real machine after the canary ran it:
- Worktree repair: 8 worktrees in
~/code/paradevstill had git records on~/.superset/....repairGitWorktreespasses every workspace path for a repo to onegit worktree repair. Git exits fatally at the first path whose parent folder is gone (here an archivedinvestigate/<name>workspace) and skips every path after it. A missing leaf folder only logs an error. Git still worked through the~/.supersetsymlink, which hid the failure. - Hook matcher:
SUPERSET_MANAGED_HOOK_PATH_PATTERNonly knew.superset(-x)andsuperset-dev-data, so since the move it treated the default home's own hook entries as foreign. - Repo config:
.paradev/is safe to use here because canary desktops (344c299f43) and this morning's production sandbox release both include #9248, which reads.paradev/. Stabledesktop-v2.0.2only reads.superset/, but the company is on canary.
How It Works
repairGitWorktrees(worktrees, legacyHomeDir)keeps only checkouts whose.gitfile or admingitdirstill names the legacy home, comparing against both the path as given and with its parent folder resolved, since git stores/private/var/...on macOS. Missing checkouts drop out the same way. Both callers (host-service, desktop) now run it on every boot instead of only when the boot rewrote database rows.- The hook matcher regexes (
agent-wrappers-common.ts,agent-wrappers-muse.ts) accept.paradev(-x)andparadev-dev-data, and still accept the old names so stale entries from old worktrees get cleaned up. git mv .superset .paradev. Config commands, scripts, READMEs (all locales), DEVELOPMENT/CONTRIBUTING, agent skills, mobile scripts,.envexamples, thecontributeplugin skill and the golden release check (test -x /workspace/.paradev/setup.cloud.sh) point at the new paths.- In the scripts:
DEV_DATA_DIR="paradev-dev-data"lives inlib/common.sh, andprod_app_homeis just~/.paradev. Output text says Paradev, the cloud tmux session isparadev, the local MCP entry isparadev-local, andSUPERSET_SCRIPT_DIRis nowPARADEV_SCRIPT_DIR. - The CLI build cache is now
~/.paradev-build-cache. .gitignoreswaps the.superset/*entries for.paradev/*and keeps.superset/andsuperset-dev-data/. Existing worktrees still have leftover untracked ports/overlay/dev data folders, which can hold a sign-in token, and these lines stopgit add -Afrom committing them.
Manual QA
- Ran the real
./.paradev/setup.shin this worktree: every step passed, it reused the existing Neon branch, wrote.envwith the same keys andSUPERSET_HOME_DIR=<worktree>/paradev-dev-data, and wrote.paradev/ports.json, which git ignores. - Host-service
loadProjectConfigon this repo resolves.paradev/config.toml→./.paradev/setup.sh/./.paradev/teardown.sh. - Teardown's dev data removal in a scratch folder: removes
paradev-dev-data, leavessuperset-dev-dataalone, and skips cleanly when the folder is absent. I didn't run real teardown, because it deletes the Neon branch. - Reproduced git's behavior by hand: a missing leaf path is non-fatal, while a missing parent folder is
fatal: Invalid path, exit 128. - On the audited machine, running
git worktree repairper worktree fixed the 8 stale records.
Testing
bun testinpackages/agent-setup(434 pass). The new repair and hook-matcher cases fail without their fixes.bun testforpackages/shared/src/project-config,packages/sandbox,packages/trpc/src/lib/sandbox/repo-hooks.test.ts, andpackages/host-service/src/daemon/DaemonSupervisor.test.tstsc --noEmitfor agent-setup, sandbox, shared, mcp and authbiome checkon the changed files,bun run check:pluginsapps/mobiletypecheck fails inNewSessionSheet.tsx, which this PR doesn't touch, so it's a failure already on main.
Rollout
- Existing worktrees re-run
./.paradev/setup.sh(or with--force) to switch toparadev-dev-data. Until then their.envkeeps pointing at the old folder, andbun scripts/dev-cli.tswon't find their dev host. - Stable
desktop-v2.0.2won't find this repo's setup scripts. That's accepted, because everyone internal is on canary. SUPERSET_*environment variables are unchanged. The app reads them, so they move with the app.
Summary by cubic
Finishes this repo's move from .superset/ to .paradev/: workspace config, per-worktree dev data, docs and scripts now use the new names, and it fixes git worktree repair skipping worktrees after a stored workspace path whose parent folder was deleted.
Bug Fixes
repairGitWorktreesskips missing worktree paths, sincegit worktree repairaborts fatally at the first path whose parent folder is gone and leaves everything after it stale. It now runs on every boot, but only touches checkouts whose git records still name the legacy home — matching both absolute and resolved-relative backlink paths — so the per-boot cost stays low.- The managed hook matcher now recognizes
~/.paradevandparadev-dev-datapaths, so a dev build replaces the installed app's Cursor, Gemini and notify hooks instead of adding its own next to them; the old.superset/superset-dev-datapatterns stay so stale entries are still reaped.
Migration
- Existing worktrees re-run
./.paradev/setup.sh(--forceto replace dev data) to point.envatparadev-dev-data;setup.sh --mcpalso drops the oldsuperset-localMCP entry. - The CLI build cache moved to
~/.paradev-build-cache. - Stable
desktop-v2.0.2still only reads.superset/; canary and production sandboxes read.paradev/.
Summary by CodeRabbit
- Developer Experience
- Development setup, teardown, workspace configuration, and data directories now use Paradev naming. Updated setup and teardown commands are available, and development tools recognize Paradev-managed hooks.
- Git worktree registration can be repaired after a home-directory move, including when other worktree entries point to deleted locations.
- Documentation
- Updated development setup and troubleshooting guidance across project documentation and translated readmes to use the Paradev workspace.