Skip to content

Commit eeeade0

Browse files
fix: wrap PowerShellToolRunner.psPath in "" (Azure#31)
1 parent 358ee2b commit eeeade0

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

lib/PowerShell/Utilities/PowerShellToolRunner.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ class PowerShellToolRunner {
2828
}
2929
static executePowerShellScriptBlock(scriptBlock, options = {}) {
3030
return __awaiter(this, void 0, void 0, function* () {
31-
yield exec.exec(`${PowerShellToolRunner.psPath} -Command`, [scriptBlock], options);
31+
yield exec.exec(`"${PowerShellToolRunner.psPath}" -Command`, [scriptBlock], options);
3232
});
3333
}
3434
}

src/PowerShell/Utilities/PowerShellToolRunner.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,6 @@ export default class PowerShellToolRunner {
1111
}
1212

1313
static async executePowerShellScriptBlock(scriptBlock: string, options: any = {}) {
14-
await exec.exec(`${PowerShellToolRunner.psPath} -Command`, [scriptBlock], options)
14+
await exec.exec(`"${PowerShellToolRunner.psPath}" -Command`, [scriptBlock], options)
1515
}
1616
}

0 commit comments

Comments
 (0)