only attempt poetry install when not present (#18811)

This commit is contained in:
Kyle Altendorf
2024-11-04 12:33:51 -07:00
committed by GitHub
parent d95a5e7cf6
commit 6a0344fb0b
2 changed files with 9 additions and 2 deletions
+5 -1
View File
@@ -102,7 +102,11 @@ foreach ($extra in $extras)
$extras_cli += $extra
}
./Setup-poetry.ps1 -pythonVersion "$pythonVersion"
if (-not (Get-Item -ErrorAction SilentlyContinue ".penv/Scripts/poetry.exe").Exists)
{
./Setup-poetry.ps1 -pythonVersion "$pythonVersion"
}
.penv/Scripts/poetry env use $(py -"$pythonVersion" -c 'import sys; print(sys.executable)')
.penv/Scripts/poetry install @extras_cli