Skip to content

fix(server-core): pass persisted gitBashPath to SDK subprocess via envOverrides - #939

Open
changjing9527 wants to merge 1 commit into
craft-ai-agents:mainfrom
changjing9527:fix/935-gitbash-path-env-overrides
Open

fix(server-core): pass persisted gitBashPath to SDK subprocess via envOverrides#939
changjing9527 wants to merge 1 commit into
craft-ai-agents:mainfrom
changjing9527:fix/935-gitbash-path-env-overrides

Conversation

@changjing9527

Copy link
Copy Markdown

…vOverrides

When gitBashPath is configured in config.json, it was not forwarded to the SDK subprocess through session envOverrides. While it was set on process.env at startup and in the gitbash.CHECK handler, it was missing from the explicit envOverrides map used when spawning the SDK subprocess for both Pi and Claude backends.

This caused the bash tool to fall back to its internal hardcoded paths ("C:\Program Files\Git\bin\bash.exe" and
"C:\Program Files (x86)\Git\bin\bash.exe"), silently ignoring the user's custom gitBashPath for non-standard Git installations.

Fixes #935

…vOverrides

When gitBashPath is configured in config.json, it was not forwarded to
the SDK subprocess through session envOverrides. While it was set on
process.env at startup and in the gitbash.CHECK handler, it was
missing from the explicit envOverrides map used when spawning the SDK
subprocess for both Pi and Claude backends.

This caused the bash tool to fall back to its internal hardcoded paths
("C:\Program Files\Git\bin\bash.exe" and
"C:\Program Files (x86)\Git\bin\bash.exe"), silently ignoring the
user's custom gitBashPath for non-standard Git installations.

Fixes craft-ai-agents#935

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@csavelief

Copy link
Copy Markdown

Hi everyone,

Any plans to merge this in the near future? If not, I'll go ahead and put together a custom build :-)

Best,

Cyrille

@changjing9527

Copy link
Copy Markdown
Author

Hi folks,
Could anyone with write access help review and approve this PR as well as the pending workflow? It’s currently blocked from merging.
Thank you!

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.

gitBashPath in config.json is not used when resolving the Bash shell

2 participants