fix(powershell): remove platform-specific execution (#7675)

This commit is contained in:
Hugo Pereira Brito
2025-05-07 11:44:13 +02:00
committed by Pepe Fagoaga
parent 8817d08a92
commit af6b0833a1
+1 -7
View File
@@ -1,5 +1,4 @@
import json
import platform
import queue
import re
import subprocess
@@ -47,12 +46,7 @@ class PowerShellSession:
This is a base implementation that should be extended by subclasses
to add specific initialization logic (e.g., credential setup).
"""
# Determine the appropriate PowerShell command based on the OS
if platform.system() == "Windows":
powershell_cmd = "powershell"
else:
powershell_cmd = "pwsh"
powershell_cmd = "pwsh"
self.process = subprocess.Popen(
[powershell_cmd, "-NoExit", "-Command", "-"],
stdin=subprocess.PIPE,