Verified Claude Code
Work across several repos with --add-dir
What it does
By default only the launch directory is accessible. --add-dir grants extra directories, useful for split frontend/backend repos or reading another repo.
How
claude --add-dir ../backend ../shared-lib
How much to trust this
| Applies to | ≥ 1.0.18 |
|---|---|
| Verified | Oct 17, 2026 · v2.1.296 · tested locally 2.1.296 的 --help 中存在;1.0.18 加入 |
| Depends on | --add-dir |
| Source | https://code.claude.com/docs/en/cli-reference (official_docs) |