19 lines
927 B
PowerShell
19 lines
927 B
PowerShell
# Dev launcher: starts the Vite UI (:5173) in a new window and the Quarkus API (:8090) here.
|
|
# Open http://localhost:5173 once both are up. Ctrl-C stops the backend.
|
|
$ErrorActionPreference = "Stop"
|
|
$root = $PSScriptRoot
|
|
$env:JAVA_HOME = "C:\Program Files\Java\jdk-21.0.11"
|
|
$mvn = "C:\Users\Dell\.m2\wrapper\dists\apache-maven-3.9.9-bin\4nf9hui3q3djbarqar9g711ggc\apache-maven-3.9.9\bin\mvn.cmd"
|
|
|
|
if (-not (Test-Path "$root\frontend\node_modules")) {
|
|
Write-Host "Installing frontend dependencies..." -ForegroundColor Cyan
|
|
Push-Location "$root\frontend"; npm install; Pop-Location
|
|
}
|
|
|
|
Write-Host "Starting Vite dev server (http://localhost:5173) in a new window..." -ForegroundColor Cyan
|
|
Start-Process powershell -ArgumentList '-NoExit', '-Command', "Set-Location `"$root\frontend`"; npm run dev"
|
|
|
|
Write-Host "Starting Quarkus dev (API on http://localhost:8090)..." -ForegroundColor Cyan
|
|
Set-Location $root
|
|
& $mvn quarkus:dev
|