openmcp-client/build_service.ps1
2025-04-11 00:05:55 +08:00

23 lines
680 B
PowerShell
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# Create resources directory if it doesn't exist
New-Item -ItemType Directory -Force -Path .\resources | Out-Null
# Start both build tasks in parallel
$jobs = @(
Start-Job -ScriptBlock {
Set-Location $using:PWD\renderer
npm run build
Move-Item -Force -Path .\dist -Destination ..\resources\renderer
}
Start-Job -ScriptBlock {
Set-Location $using:PWD\service
npm run build
Move-Item -Force -Path .\dist -Destination ..\resources\service
}
)
# Wait for all jobs to complete
Wait-Job -Job $jobs | Out-Null
Receive-Job -Job $jobs
Remove-Job -Job $jobs
Write-Host "构建完成dist文件已移动到resources目录"