mirror of
https://github.com/Aider-AI/aider.git
synced 2025-06-02 18:54:59 +00:00
style: format command string for PowerShell execution
This commit is contained in:
parent
4605969921
commit
1327c1e893
1 changed files with 3 additions and 1 deletions
|
@ -31,7 +31,9 @@ def run_cmd_subprocess(command, verbose=False):
|
||||||
# Use PowerShell if it's the parent process
|
# Use PowerShell if it's the parent process
|
||||||
if "powershell" in os.environ.get("PSModulePath", "").lower():
|
if "powershell" in os.environ.get("PSModulePath", "").lower():
|
||||||
shell = "powershell"
|
shell = "powershell"
|
||||||
command = f'powershell -ExecutionPolicy Bypass -Command "& {{({command}) | Out-String}}"'
|
command = (
|
||||||
|
f'powershell -ExecutionPolicy Bypass -Command "& {{({command}) | Out-String}}"'
|
||||||
|
)
|
||||||
else:
|
else:
|
||||||
shell = "cmd"
|
shell = "cmd"
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue