Skip to content

Commit 6a3827e

Browse files
committed
fix: use splatting to pass arguments from a powershell scope
May resolve issue npm#7375
1 parent 866b5ee commit 6a3827e

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

bin/npm.ps1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,9 @@ if (Test-Path $NPM_PREFIX_NPM_CLI_JS) {
2424

2525
# Support pipeline input
2626
if ($MyInvocation.ExpectingInput) {
27-
$input | & $NODE_EXE $NPM_CLI_JS $args
27+
$input | & $NODE_EXE $NPM_CLI_JS @args
2828
} else {
29-
& $NODE_EXE $NPM_CLI_JS $args
29+
& $NODE_EXE $NPM_CLI_JS @args
3030
}
3131

3232
exit $LASTEXITCODE

bin/npx.ps1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,9 @@ if (Test-Path $NPM_PREFIX_NPX_CLI_JS) {
2424

2525
# Support pipeline input
2626
if ($MyInvocation.ExpectingInput) {
27-
$input | & $NODE_EXE $NPX_CLI_JS $args
27+
$input | & $NODE_EXE $NPX_CLI_JS @args
2828
} else {
29-
& $NODE_EXE $NPX_CLI_JS $args
29+
& $NODE_EXE $NPX_CLI_JS @args
3030
}
3131

3232
exit $LASTEXITCODE

0 commit comments

Comments
 (0)