From 2cfef629d35182320847fe22b67234c3f7312efa Mon Sep 17 00:00:00 2001 From: Jan De Dobbeleer Date: Fri, 27 Dec 2024 16:51:21 +0100 Subject: [PATCH] fix(pwsh): silence link output --- src/shell/link_test.go | 2 +- src/shell/pwsh.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/shell/link_test.go b/src/shell/link_test.go index 92ab7ef..16517f6 100644 --- a/src/shell/link_test.go +++ b/src/shell/link_test.go @@ -19,7 +19,7 @@ func TestLinkCommand(t *testing.T) { { Case: "PWSH", Shell: PWSH, - Expected: "New-Item -Path \"foo\" -ItemType SymbolicLink -Value \"bar\" -Force", + Expected: "New-Item -Path \"foo\" -ItemType SymbolicLink -Value \"bar\" -Force | Out-Null", }, { Case: "CMD", diff --git a/src/shell/pwsh.go b/src/shell/pwsh.go index 2081e12..5c555c9 100644 --- a/src/shell/pwsh.go +++ b/src/shell/pwsh.go @@ -73,7 +73,7 @@ func (e *Env) pwsh() *Env { } func (l *Link) pwsh() *Link { - template := `New-Item -Path {{ formatString .Name }} -ItemType SymbolicLink -Value {{ formatString .Target }} -Force` + template := `New-Item -Path {{ formatString .Name }} -ItemType SymbolicLink -Value {{ formatString .Target }} -Force | Out-Null` l.template = template return l }