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:
Kagami Sascha Rosylight 2022-03-28 19:13:18 +00:00
Родитель c2f751983d
Коммит 4c260516df
1 изменённых файлов: 1 добавлений и 1 удалений

Просмотреть файл

@ -1,7 +1,7 @@
$mypath = $MyInvocation.MyCommand.Path
$machpath = $mypath.substring(0, $mypath.length - 4)
if (Get-Command py) {
if (Get-Command py -ErrorAction SilentlyContinue) {
$python_executable = "py"
} else {
$python_executable = "python"