File tree Expand file tree Collapse file tree
src/hooks/non-interactive-env Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -52,8 +52,10 @@ export function createNonInteractiveEnvHook(_ctx: PluginInput) {
5252 // The env vars (GIT_EDITOR=:, EDITOR=:, etc.) must ALWAYS be injected
5353 // for git commands to prevent interactive prompts.
5454
55- const shellType = process . platform === "win32" ? "powershell" : "unix"
56- const envPrefix = buildEnvPrefix ( NON_INTERACTIVE_ENV , shellType )
55+ // Always use unix-style prefix: this hook only processes Bash tool commands
56+ // (guarded by the tool check above), so the prefix must be bash-compatible
57+ // regardless of the host OS shell (e.g., PowerShell on Windows).
58+ const envPrefix = buildEnvPrefix ( NON_INTERACTIVE_ENV , "unix" )
5759
5860 // Check if the command already starts with the prefix to avoid stacking.
5961 // This maintains the non-interactive behavior and makes the operation idempotent.
You can’t perform that action at this time.
0 commit comments