Files

16 lines
533 B
PowerShell

# Build shell frontend source -> renderer/dist (self-contained direction; old webhost untouched)
# Usage: npm run copy-renderer
$ErrorActionPreference = "Stop"
$fd = Join-Path $PSScriptRoot "..\frontend"
if (-not (Test-Path (Join-Path $fd "node_modules\vite\bin\vite.js"))) {
Write-Error "frontend deps missing; run: cd desktop\electron-shell\frontend && npm install"
}
Push-Location $fd
try {
npm run build
if ($LASTEXITCODE -ne 0) { throw "vite build failed" }
} finally {
Pop-Location
}
Write-Host "renderer/dist rebuilt"