Bug 1761633 - Silence the possible error from Get-Command r=mhentges DONTBUILD
Differential Revision: https://phabricator.services.mozilla.com/D142159
This commit is contained in:
2
mach.ps1
2
mach.ps1
@@ -1,7 +1,7 @@
|
|||||||
$mypath = $MyInvocation.MyCommand.Path
|
$mypath = $MyInvocation.MyCommand.Path
|
||||||
$machpath = $mypath.substring(0, $mypath.length - 4)
|
$machpath = $mypath.substring(0, $mypath.length - 4)
|
||||||
|
|
||||||
if (Get-Command py) {
|
if (Get-Command py -ErrorAction SilentlyContinue) {
|
||||||
$python_executable = "py"
|
$python_executable = "py"
|
||||||
} else {
|
} else {
|
||||||
$python_executable = "python"
|
$python_executable = "python"
|
||||||
|
|||||||
Reference in New Issue
Block a user