Bash tool on Windows Git Bash cannot find common binaries (git, task, ls) after 2.1.x update

Resolved 💬 3 comments Opened Apr 16, 2026 by GunarsK Closed May 27, 2026

Environment

  • OS: Windows 11 (10.0.26200)
  • Shell: Git Bash (bash from C:\Program Files\Git)
  • Claude Code version: reproduces on latest 2.1.x at time of filing
  • Regression: Yes — worked ~2 days ago, broke after a recent update

Symptoms

Inside Claude Code's Bash tool, common binaries are not resolvable on the PATH, even though they exist and work from a normal PowerShell / Git Bash terminal on the same machine:

  • gitcommand not found
  • taskcommand not found
  • ls, grep, find, wc, which, wherecommand not found
  • powershell.execommand not found

echo $PATH inside the Bash tool prints the Windows PATH (;-separated) prepended to a handful of :-separated unix-style plugin-cache entries. Bash treats the whole string as :-separated, so only the tail of the string resolves — effectively nothing from the system PATH works.

What still works

  • Shell builtins (echo, cd, pwd)
  • Binaries invoked by absolute unix path that land inside MSYS:
  • /mingw64/bin/git works
  • /usr/bin/ls works
  • Binaries invoked by absolute Windows-style unix path inside Program Files:
  • "/c/Program Files/GitHub CLI/gh.exe" works (with quoting)
  • BUT: some Windows-side binaries under C:\Users\<user>\go\bin\ are unreachable from either form (/c/Users/.../task.exe errors with No such file or directory, even when the file exists — verified by /usr/bin/ls on the parent directory).

Repro

  1. Windows 11, Git Bash as the Claude Code shell
  2. Fresh session
  3. Ask Claude to run git status or task --version in a project
  4. Observe command not found

Impact

Cannot run task, git, or any CI/test tooling from inside Claude Code via the bare command name. Work that relies on Claude running its own verification (task ci:all, git status before commits, go test, etc.) is blocked — the user must shell out manually. Absolute-path workarounds help for a few tools but are brittle (spaces, drive-letter translation, missing paths).

Workaround

None clean. Absolute unix-path invocation works for a subset (/mingw64/bin/git, /usr/bin/ls). Space-containing Windows paths need shell quoting and only sometimes resolve.

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗