Skip to content

chore(claude): silence native install check for mise-managed install#38

Merged
vaintrub merged 1 commit into
masterfrom
chore/claude-mise-install-pin
Jun 2, 2026
Merged

chore(claude): silence native install check for mise-managed install#38
vaintrub merged 1 commit into
masterfrom
chore/claude-mise-install-pin

Conversation

@vaintrub

@vaintrub vaintrub commented Jun 2, 2026

Copy link
Copy Markdown
Owner

Problem

~/.claude.json records installMethod: native, so Claude Code's startup/doctor check (rLq) probes ~/.local/bin/claude and warns on every launch. But claude is installed via mise/aqua (binary under ~/.local/share/mise/installs/..., on PATH via mise activation), so the native path is empty:

installMethod is native, but claude command not found at /home/vaintrub/.local/bin/claude

Fix

Instead of faking the native layout with a symlink, set two recognized env vars in .chezmoitemplates/claude-settings-base.json~/.claude/settings.json:

"env": {
  "DISABLE_INSTALLATION_CHECKS": "1",
  "DISABLE_AUTOUPDATER": "1"
}
  • DISABLE_INSTALLATION_CHECKS=1 — verified against the binary: the check function early-returns (if (DISABLE_INSTALLATION_CHECKS) return []) before building any warning, so the native-mismatch warning and npm-deprecation / install-mismatch notices are suppressed. This is the intended escape hatch for externally-managed installs.
  • DISABLE_AUTOUPDATER=1 — native self-updater stays off; mise/aqua owns versioning (mise upgrade aqua-anthropics-claude-code). autoUpdates:false was already set per-machine; this makes it portable.

Why not a symlink / not editing installMethod

  • A ~/.local/bin/claude → mise-shim symlink works but is a fake-native-layout hack.
  • Editing installMethod to a non-native value is worse: the binary's cleanup path Y08 runs when installMethod !== "native" and unlinks ~/.local/bin/claude — and ~/.claude.json is runtime-rewritten and not chezmoi-managed (non-portable).
  • The env-var approach is portable via chezmoi, uses first-class recognized flags, and touches no filesystem outside settings.

Notes

  • No change to what runs: claude still resolves via mise's activated install dir.
  • DISABLE_INSTALLATION_CHECKS also silences npm-deprecation notices — desired for an externally-managed install.

~/.claude.json records installMethod:native, so Claude Code's doctor
probes ~/.local/bin/claude and warns on every startup — but claude is
installed via mise/aqua, not the native installer:

    installMethod is native, but claude command not found at ~/.local/bin/claude

Set two recognized env vars in settings instead of faking the native
layout:

- DISABLE_INSTALLATION_CHECKS=1 — the install-integrity checks early-return,
  so the warning (and npm-deprecation / install-mismatch notices) is gone.
  This is the intended escape hatch for externally-managed installs.
- DISABLE_AUTOUPDATER=1 — the native self-updater stays off; mise/aqua owns
  versioning (mise upgrade aqua-anthropics-claude-code).
@vaintrub vaintrub force-pushed the chore/claude-mise-install-pin branch from 00d6ab1 to aeecdd5 Compare June 2, 2026 20:08
@vaintrub vaintrub changed the title chore(claude): pin install to mise via managed symlink chore(claude): silence native install check for mise-managed install Jun 2, 2026
@vaintrub vaintrub merged commit 2cefbec into master Jun 2, 2026
3 checks passed
@vaintrub vaintrub deleted the chore/claude-mise-install-pin branch June 2, 2026 20:12
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.

1 participant