# appsONLINE Launcher - PowerShell Script # This script launches the appsONLINE application Write-Host "`n╔════════════════════════════════════════╗" -ForegroundColor Cyan Write-Host "║ appsONLINE Launcher ║" -ForegroundColor Cyan Write-Host "║ MVC Application Management ║" -ForegroundColor Cyan Write-Host "╚════════════════════════════════════════╝`n" -ForegroundColor Cyan # Check if Node.js is installed $nodeCheck = Get-Command node -ErrorAction SilentlyContinue if ($null -eq $nodeCheck) { Write-Host "❌ Error: Node.js is not installed!" -ForegroundColor Red Write-Host "" Write-Host "Please download and install Node.js from:" -ForegroundColor Yellow Write-Host "https://nodejs.org/" -ForegroundColor Cyan Write-Host "" exit 1 } $nodeVersion = & node --version Write-Host "✅ Node.js $nodeVersion found" -ForegroundColor Green Write-Host "" # Check if npm packages are installed $nodeModulesPath = Join-Path -Path $PSScriptRoot -ChildPath "node_modules" if (-not (Test-Path -Path $nodeModulesPath)) { Write-Host "📦 Installing dependencies (first time)..." -ForegroundColor Yellow npm install if ($LASTEXITCODE -ne 0) { Write-Host "❌ Failed to install dependencies!" -ForegroundColor Red exit 1 } Write-Host "✅ Dependencies installed" -ForegroundColor Green Write-Host "" } Write-Host "🚀 Starting appsONLINE launcher..." -ForegroundColor Green Write-Host "" Write-Host "The application will open in a new window." -ForegroundColor Yellow Write-Host "Press Ctrl+C to stop the application." -ForegroundColor Yellow Write-Host "" # Start the application npm start if ($LASTEXITCODE -ne 0) { Write-Host "❌ Error starting the application!" -ForegroundColor Red Write-Host "" }