[2026-05-27] 포맷 후 복구 설치 스크립트 추가
This commit is contained in:
@@ -0,0 +1,25 @@
|
||||
$ErrorActionPreference = "Stop"
|
||||
|
||||
$Root = Split-Path -Parent (Split-Path -Parent $MyInvocation.MyCommand.Path)
|
||||
Set-Location $Root
|
||||
|
||||
. "$Root\scripts\stockbot_env.ps1"
|
||||
$Python = Resolve-StockBotPython -Project $Root
|
||||
$Requirements = Join-Path $Root "requirements.txt"
|
||||
$Wheelhouse = Join-Path $Root "vendor\wheels"
|
||||
|
||||
if (-not (Test-Path $Requirements)) {
|
||||
throw "requirements.txt not found: $Requirements"
|
||||
}
|
||||
|
||||
if (Test-Path $Wheelhouse) {
|
||||
$WheelFiles = Get-ChildItem -Path $Wheelhouse -Filter "*.whl" -ErrorAction SilentlyContinue
|
||||
if ($WheelFiles.Count -gt 0) {
|
||||
Write-Host "[install] using local wheelhouse: $Wheelhouse"
|
||||
& $Python -m pip install --no-index --find-links $Wheelhouse -r $Requirements
|
||||
exit $LASTEXITCODE
|
||||
}
|
||||
}
|
||||
|
||||
Write-Host "[install] using online package index"
|
||||
& $Python -m pip install -r $Requirements
|
||||
Reference in New Issue
Block a user