* Returns the canonical git repo root if available, otherwise falls back to * the stable project root. Uses findCanonicalGitRoot so all worktrees of the * same repo share one auto-memory directory (anthropics/claude-code#24382).
()
| 203 | * same repo share one auto-memory directory (anthropics/claude-code#24382). |
| 204 | */ |
| 205 | function getAutoMemBase(): string { |
| 206 | return findCanonicalGitRoot(getProjectRoot()) ?? getProjectRoot() |
| 207 | } |
| 208 | |
| 209 | /** |
| 210 | * Returns the auto-memory directory path. |
no test coverage detected