feat(electron-shell): 补录壳子源码(排除运行环境与构建产物)
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
# 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"
|
||||
Reference in New Issue
Block a user