MCPcopy Create free account
hub / github.com/Work-Fisher/code-claw / execute_powershell

Function execute_powershell

claw-code/rust/crates/tools/src/lib.rs:2672–2681  ·  view source on GitHub ↗
(input: PowerShellInput)

Source from the content-addressed store, hash-verified

2670
2671#[allow(clippy::needless_pass_by_value)]
2672fn execute_powershell(input: PowerShellInput) -> std::io::Result<runtime::BashCommandOutput> {
2673 let _ = &input.description;
2674 let shell = detect_powershell_shell()?;
2675 execute_shell_command(
2676 shell,
2677 &input.command,
2678 input.timeout,
2679 input.run_in_background,
2680 )
2681}
2682
2683fn detect_powershell_shell() -> std::io::Result<&'static str> {
2684 if command_exists("pwsh") {

Callers 1

run_powershellFunction · 0.85

Calls 2

detect_powershell_shellFunction · 0.85
execute_shell_commandFunction · 0.85

Tested by

no test coverage detected