Files
PCFAnalysis/scripts/run.ps1
T

9 lines
332 B
PowerShell

$ErrorActionPreference = "Stop"
$Root = Split-Path -Parent $PSScriptRoot
$VenvPython = Join-Path $Root ".venv\Scripts\python.exe"
if (-not (Test-Path $VenvPython)) {
throw "未找到虚拟环境。请先运行 scripts\install_offline.ps1。"
}
Set-Location $Root
& $VenvPython -m uvicorn app.main:app --host 127.0.0.1 --port 7001