Move worktrees to ~/.Conclave to avoid Windows MAX_PATH issues#50
Conversation
Worktrees previously lived next to the SQLite db (e.g. %AppData%\Roaming\Conclave\worktrees), which on Windows ate ~50 characters of the 260-char path budget before any repo content. Move them to ~/.Conclave on all platforms so deep file paths inside a worktree stay clear of MAX_PATH. Existing sessions keep working because each session row stores its absolute worktree_path; only newly created sessions land under the new root. Fixes #49.
Greptile SummaryThis PR moves the git worktree root from Confidence Score: 5/5Safe to merge — minimal, focused change with no logic alterations and no data migration risk. Both changed files have only targeted, correct modifications. The new No files require special attention. Important Files Changed
Sequence DiagramsequenceDiagram
participant App
participant SessionManager
participant Database
participant FileSystem
App->>SessionManager: Open(tokens)
SessionManager->>Database: DefaultPath()
Database-->>SessionManager: ~/Library/.../conclave.db (platform-specific)
SessionManager->>Database: Open(dbPath)
Database->>FileSystem: CreateDirectory(db parent dir)
Database-->>SessionManager: db instance
SessionManager->>Database: DefaultWorktreeRoot()
Note over Database: Always returns ~/.Conclave<br/>(platform-uniform)
Database-->>SessionManager: ~/.Conclave
SessionManager->>SessionManager: new SessionManager(db, "~/.Conclave", tokens)
SessionManager->>FileSystem: CreateDirectory("~/.Conclave")
Note over SessionManager,FileSystem: New sessions use ~/.Conclave/<projectId>/<slug><br/>Old sessions unchanged (absolute path in DB)
Reviews (1): Last reviewed commit: "Update new-session modal preview to show..." | Re-trigger Greptile |
Summary
%AppData%\Roaming\Conclave\worktrees\…, which burns ~50 chars of the 260-charMAX_PATHbudget before any repo content is appended. Deep file paths inside a worktree (e.g. nestedViews/Shell/...files plus git's own.git/worktrees/<name>/index.lock) push some users past the limit.Database.DefaultWorktreeRoot()returning~/.Conclaveon every platform, and pointsSessionManager.Open()at it.worktree_path, so only newly-created sessions land under the new root. No migration needed.Fixes #49.