Skip to content

feat(cli): detect claude binary from VS Code extensions + configurable detection order - #21

Merged
uaoa merged 1 commit into
uaoa:mainfrom
Natakout:feat/detect-claude-in-vscode-extensions
Jul 21, 2026
Merged

uaoa merged 1 commit into
uaoa:mainfrom
Natakout:feat/detect-claude-in-vscode-extensions

Conversation

@Natakout

Copy link
Copy Markdown
Contributor

Summary

Adds a new vscodeExtension detection source: the claude binary shipped with
the official anthropic.claude-code extension. Resolution goes through the
VS Code API (extensionUri) first, then falls back to scanning extension
directories (~/.vscode-server, ~/.vscode, plus Insiders/forks). Works both
locally and in remote setups (SSH / WSL / devcontainers); when several versions
are installed, the newest one wins.

New setting

claudeCommit.detectionOrder lets users define the order of detection sources
(path, vscodeExtension, shellProfile, commonPaths). First match wins;
omitted sources are tried last. The cached path is invalidated when either
detectionOrder or cliPath changes.

Changes

  • src/cli/detection.ts — new source + ordering logic
  • src/extension.ts — passes the extension context to the resolver
  • package.json — declares the detectionOrder setting
  • README.md — documents both

Adds the vscodeExtension detection source — the binary shipped with the
official anthropic.claude-code extension. Resolved first through the vscode
API (extensionUri), then by scanning extension directories: ~/.vscode-server,
~/.vscode and insiders/forks. Works both locally and in remote setups
(SSH/WSL/devcontainer); when several versions are installed, the newest wins.

The new claudeCommit.detectionOrder setting lets users define the order of
sources (path, vscodeExtension, shellProfile, commonPaths) — first match wins,
omitted sources are tried last. The cached path is invalidated when
detectionOrder or cliPath changes.
@uaoa
uaoa merged commit 7ae5379 into uaoa:main Jul 21, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants