-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathstart.ps1
More file actions
86 lines (74 loc) · 4.36 KB
/
start.ps1
File metadata and controls
86 lines (74 loc) · 4.36 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
# QuantResearch Quick Start Script
# This script starts both backend and frontend servers
Write-Host "🚀 Starting QuantResearch Application..." -ForegroundColor Cyan
Write-Host ""
# Check if we're in the right directory
$projectRoot = "c:\Users\PRAJWAL\OneDrive\Desktop\quantresearch\QuantResearch"
if (-not (Test-Path $projectRoot)) {
Write-Host "❌ Error: Project directory not found!" -ForegroundColor Red
Write-Host "Expected location: $projectRoot" -ForegroundColor Yellow
exit 1
}
Set-Location $projectRoot
# Check Python installation
Write-Host "🔍 Checking Python installation..." -ForegroundColor Yellow
try {
$pythonVersion = python --version 2>&1
Write-Host "✅ $pythonVersion" -ForegroundColor Green
} catch {
Write-Host "❌ Python not found. Please install Python 3.11+" -ForegroundColor Red
exit 1
}
# Check Node.js installation
Write-Host "🔍 Checking Node.js installation..." -ForegroundColor Yellow
try {
$nodeVersion = node --version 2>&1
Write-Host "✅ Node.js $nodeVersion" -ForegroundColor Green
} catch {
Write-Host "❌ Node.js not found. Please install Node.js" -ForegroundColor Red
exit 1
}
Write-Host ""
Write-Host "📝 To start the application, you need TWO terminal windows:" -ForegroundColor Cyan
Write-Host ""
Write-Host "━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━" -ForegroundColor Gray
Write-Host "TERMINAL 1 - Backend Server (FastAPI)" -ForegroundColor Yellow
Write-Host "━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━" -ForegroundColor Gray
Write-Host ""
Write-Host "cd `"$projectRoot`"" -ForegroundColor White
Write-Host "uvicorn src.quant_research_starter.api.main:app --reload --port 8000 --host 0.0.0.0" -ForegroundColor White
Write-Host ""
Write-Host "Backend will be available at: http://localhost:8000" -ForegroundColor Green
Write-Host "API Documentation: http://localhost:8000/docs" -ForegroundColor Green
Write-Host ""
Write-Host "━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━" -ForegroundColor Gray
Write-Host "TERMINAL 2 - Frontend Server (React + Vite)" -ForegroundColor Yellow
Write-Host "━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━" -ForegroundColor Gray
Write-Host ""
Write-Host "cd `"$projectRoot\src\quant_research_starter\frontend\cauweb`"" -ForegroundColor White
Write-Host "npm run dev" -ForegroundColor White
Write-Host ""
Write-Host "Frontend will be available at: http://localhost:3003" -ForegroundColor Green
Write-Host ""
Write-Host "━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━" -ForegroundColor Gray
Write-Host "Quick Access URLs" -ForegroundColor Cyan
Write-Host "━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━" -ForegroundColor Gray
Write-Host "🌐 Frontend App: http://localhost:3003" -ForegroundColor White
Write-Host "🔌 Backend API: http://localhost:8000" -ForegroundColor White
Write-Host "📚 API Docs: http://localhost:8000/docs" -ForegroundColor White
Write-Host "❤️ Health Check: http://localhost:8000/api/health" -ForegroundColor White
Write-Host ""
Write-Host "━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━" -ForegroundColor Gray
Write-Host "Do you want to start the backend server now? (Y/N)" -ForegroundColor Yellow
$response = Read-Host
Write-Host ""
if ($response -eq 'Y' -or $response -eq 'y') {
Write-Host "🚀 Starting Backend Server..." -ForegroundColor Cyan
Write-Host "📖 For full documentation, see: SETUP_COMPLETE.md" -ForegroundColor Gray
Write-Host ""
# Start backend server
uvicorn src.quant_research_starter.api.main:app --reload --port 8000 --host 0.0.0.0
} else {
Write-Host "✅ Setup information displayed. Start servers manually when ready." -ForegroundColor Green
Write-Host "📖 For detailed documentation, see: SETUP_COMPLETE.md" -ForegroundColor Gray
}