Skip to main content

Module windows_shell

Module windows_shell 

Source
Expand description

Shared Windows shell selection for foreground and background bash commands.

Mirrors OpenCode’s resolver: prefer modern PowerShell (pwsh.exe), fall back to Windows PowerShell (powershell.exe), then to cmd.exe.

Compiled on all platforms so the cross-platform retry-decision unit tests in commands::bash::try_spawn_with_fallback can run on macOS/Linux dev machines. Production callers (commands::bash::spawn_shell_command and bash_background::registry::detached_shell_command_for) are #[cfg(windows)].