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.6 Home All releases olderv2.1.5 v2.1.7newer
Claude Code v2.1.6

Git Token Injection for Private Repository Cloning

What

Claude Code now automatically injects authentication tokens when cloning HTTPS repositories, supporting GitHub, GitLab, and Bitbucket.

Usage: Set the appropriate environment variable and clone private repositories seamlessly:

export GITHUB_TOKEN=your_token
# Or: GH_TOKEN, GITLAB_TOKEN, GL_TOKEN, BITBUCKET_TOKEN
Details
  • Automatically detects authentication failures and retries with token injection
  • Supports GITHUB_TOKEN/GH_TOKEN for github.com
  • Supports GITLAB_TOKEN/GL_TOKEN for gitlab.com and GitLab self-hosted instances
  • Supports BITBUCKET_TOKEN for bitbucket.org
  • Tokens in error messages are automatically redacted for security
  • Preserves SSH_AUTH_SOCK for SSH key agent forwarding
Evidence

K55() at line 299739 (token injection logic, contains "Injecting GitHub token into clone URL")

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

Related

Other releases about the same thing. Found by shared names or similar wording; neither means one caused the other.

See this entry in the whole of v2.1.6 →