[DOCS] CLI reference and headless docs missing --bare flag documentation
Documentation Type
Missing documentation (feature not documented)
Documentation Location
https://code.claude.com/docs/en/cli-reference
Section/Topic
"Flags" table in CLI reference, and the "Non-interactive mode" section in headless docs
Current Documentation
No documentation currently exists for the --bare flag. The CLI reference flags table (which lists --print, --output-format, --model, etc.) has no --bare entry. The headless docs (headless.md) describe -p / --print usage but do not mention --bare as a companion flag.
The apiKeyHelper setting is documented in settings.md and authentication.md, but only in the context of general auth configuration, not as a --bare-specific requirement.
What's Wrong or Missing?
Changelog v2.1.81 added --bare flag for scripted -p calls. This flag:
- Skips hooks, LSP, plugin sync, and skill directory walks for faster startup
- Requires
ANTHROPIC_API_KEYor anapiKeyHelpervia--settings(OAuth and keychain auth are disabled) - Fully disables auto-memory
None of this is documented anywhere. Users writing scripts that call claude -p for automation have no way to discover or learn about --bare from the docs.
Suggested Improvement
A. Add --bare row to the CLI reference flags table
Add after the --print entry:
| Flag | Description |
|------|-------------|
| --bare | Lightweight mode for scripted -p calls. Skips hooks, LSP, plugin sync, and skill directory walks. Requires ANTHROPIC_API_KEY or an apiKeyHelper via --settings (OAuth and keychain auth are disabled). Auto-memory is fully disabled. |
B. Add a section to the headless docs
Add a "Lightweight scripted mode" subsection to the headless/non-interactive docs explaining when to use --bare vs plain -p, the startup performance benefit, and the auth requirements.
Impact
High - Prevents users from using a feature
Additional Context
Affected Pages:
| Page | Context |
|------|---------|
| https://code.claude.com/docs/en/cli-reference | Flags table missing --bare entry |
| https://code.claude.com/docs/en/headless | Non-interactive mode docs missing --bare usage |
| https://code.claude.com/docs/en/settings | apiKeyHelper documented but not linked to --bare requirement |
| https://code.claude.com/docs/en/authentication | Auth precedence rules don't mention --bare constraints |
Total scope: 4 pages affected
Source: Changelog v2.1.81 — "Added --bare flag for scripted -p calls — skips hooks, LSP, plugin sync, and skill directory walks; requires ANTHROPIC_API_KEY or an apiKeyHelper via --settings (OAuth and keychain auth disabled); auto-memory fully disabled"
This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗