Skip to content

Commit 75f6426

Browse files
committed
Remove RunPowerShell method from utils
1 parent 3b82d1c commit 75f6426

File tree

1 file changed

+0
-9
lines changed

1 file changed

+0
-9
lines changed

pkg/utils/utils.go

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ import (
44
"errors"
55
"fmt"
66
"os"
7-
"os/exec"
87
"strings"
98

109
"golang.org/x/sys/windows"
@@ -25,14 +24,6 @@ func EnsureLongPath(path string) string {
2524
return path
2625
}
2726

28-
func RunPowershellCmd(command string, envs ...string) ([]byte, error) {
29-
cmd := exec.Command("powershell", "-Mta", "-NoProfile", "-Command", command)
30-
cmd.Env = append(os.Environ(), envs...)
31-
klog.V(8).Infof("Executing command: %q", cmd.String())
32-
out, err := cmd.CombinedOutput()
33-
return out, err
34-
}
35-
3627
func IsPathValid(path string) (bool, error) {
3728
pathString, err := windows.UTF16PtrFromString(path)
3829
if err != nil {

0 commit comments

Comments
 (0)