Source Intelligence

DisclaimerUnofficial, and not affiliated with Anthropic. Nearly all of this is read straight out of what ships: npm bundles, captured prompts, published docs. Anthropic's own notes go in verbatim, marked as theirs. The rest is my reading, and every entry carries the strings behind it. If one looks wrong, vote it down and say why.

All of v2.1.21 Home All releases olderv2.1.20 v2.1.22newer
Claude Code v2.1.21

Shell Completion Cache Management

What

Shell completion files are now automatically generated and cached, with auto-regeneration on updates.

Usage

Completion files are stored at:

  • ~/.claude/completion.bash for bash
  • ~/.claude/completion.zsh for zsh
  • ~/.claude/completion.fish for fish (stored in $XDG_CONFIG_HOME/fish/config.fish)
Details
  • Completion caches are automatically regenerated after Claude Code updates
  • Uses claude completion <shell-flag> --output <cache-file> under the hood
  • Logs show update: Regenerating <shell> completion cache and update: Regenerated <shell> completion cache at <path>
  • Improves shell startup performance by avoiding regenerating completions on every shell launch
Evidence

k69() at line 184272-184299 (shell detection, contains "completion.bash", "completion.fish", "completion.zsh"), wq6() at line 184307 (cache regeneration, contains "update: Regenerating" and "completion cache")

Strings lifted out of the shipped bundle, so the claim above can be checked against them.

See this entry in the whole of v2.1.21 →