Use a Custom Directory
Overview
By default, Claude Plan Viewer looks for plans in ~/.claude/plans/. If your Claude Code installation uses a different location, you can specify a custom path using the --claude-dir flag or the CLAUDE_DIR environment variable.
CLI Flag
Use --claude-dir (or -c) to specify a custom .claude directory:
bash
claude-plan-viewer --claude-dir /path/to/.claudeShort form:
bash
claude-plan-viewer -c /path/to/.claudeEnvironment Variable
Set the CLAUDE_DIR environment variable for persistent configuration:
bash
export CLAUDE_DIR=/path/to/.claude
claude-plan-viewerbash
CLAUDE_DIR=/path/to/.claude claude-plan-viewerbash
export CLAUDE_DIR=/path/to/.claudePrecedence
When both the CLI flag and environment variable are set, the CLI flag takes precedence:
| Configuration | Source Used |
|---|---|
| Neither set | ~/.claude (default) |
Only CLAUDE_DIR set | CLAUDE_DIR value |
Only --claude-dir set | --claude-dir value |
| Both set | --claude-dir value |
Use Cases
- Non-Standard Installation - Point to a Claude Code installation in a custom location
- Multiple Installations - Switch between different Claude Code configurations
- Network Storage - Access plans stored on a mounted network drive or shared filesystem
- Docker/Container - Mount and access plans from a containerized environment
Examples
bash
claude-plan-viewer --claude-dir /Volumes/External/.claudebash
claude-plan-viewer --claude-dir /mnt/shared/team-claudebash
claude-plan-viewer --claude-dir /custom/path/.claude --json -o backup.jsonTIP
The specified directory should contain plans/ and optionally projects/ subdirectories matching the standard Claude Code structure.