| .PHONY: help install install-frontend install-docs build-frontend build-docs clean test run dev dev-frontend dev-docs start-all stop-all dev-full docker-up docker-down deploy-databricks |
|
|
| help: |
| @echo "π¦· Open Navigator - Makefile Commands" |
| @echo "====================================================" |
| @echo "" |
| @echo "π Quick Start:" |
| @echo " make start-all - Start ALL services (API + Dashboard + Docs) with tmux" |
| @echo " make stop-all - Stop all running services" |
| @echo "" |
| @echo "π Python Backend:" |
| @echo " make install - Install Python dependencies in venv" |
| @echo " make dev - Start backend with auto-reload" |
| @echo " make run - Start backend (production)" |
| @echo "" |
| @echo "βοΈ React Dashboard:" |
| @echo " make install-frontend - Install dashboard npm dependencies" |
| @echo " make build-frontend - Build React dashboard for production" |
| @echo " make dev-frontend - Start dashboard dev server" |
| @echo "" |
| @echo "π Documentation Site:" |
| @echo " make install-docs - Install Docusaurus dependencies" |
| @echo " make build-docs - Build documentation for production" |
| @echo " make dev-docs - Start documentation dev server" |
| @echo "" |
| @echo "βοΈ Deployment:" |
| @echo " make deploy-databricks - Deploy to Databricks Apps" |
| @echo "" |
| @echo "π³ Docker:" |
| @echo " make docker-up - Start Docker containers" |
| @echo " make docker-down - Stop Docker containers" |
| @echo "" |
| @echo "π§ͺ Testing:" |
| @echo " make test - Run test suite" |
| @echo " make clean - Remove build artifacts" |
| @echo "" |
|
|
| install: |
| @echo "π¦ Creating virtual environment and installing dependencies..." |
| @chmod +x install.sh |
| @./install.sh |
|
|
| install-frontend: |
| @echo "π¦ Installing dashboard dependencies..." |
| @cd frontend && npm install |
| @echo "β
Dashboard dependencies installed!" |
|
|
| install-docs: |
| @echo "π¦ Installing documentation dependencies..." |
| @cd website && npm install |
| @echo "β
Documentation dependencies installed!" |
|
|
| build-frontend: |
| @echo "π¨ Building React dashboard..." |
| @cd frontend && npm run build |
| @echo "β
Dashboard built to api/static/" |
|
|
| build-docs: |
| @echo "π¨ Building documentation site..." |
| @cd website && npm run build |
| @echo "β
Documentation built to website/build/" |
|
|
| clean: |
| @echo "π§Ή Cleaning up..." |
| @rm -rf .venv venv |
| @rm -rf frontend/node_modules frontend/dist |
| @rm -rf website/node_modules website/build website/.docusaurus |
| @rm -rf api/static |
| @rm -rf __pycache__ |
| @find . -type d -name "__pycache__" -exec rm -rf {} + 2>/dev/null || true |
| @find . -type f -name "*.pyc" -delete |
| @find . -type f -name "*.pyo" -delete |
| @rm -rf .pytest_cache |
| @rm -rf .coverage |
| @rm -rf htmlcov |
| @rm -rf dist |
| @rm -rf build |
| @rm -rf *.egg-info |
| @rm -rf logs/*.pid logs/*.log |
| @echo "β
Cleanup complete" |
|
|
| test: |
| @echo "π§ͺ Running tests..." |
| @. venv/bin/activate && pytest tests/ -v |
|
|
| run: build-frontend |
| @echo "π Starting application (production mode)..." |
| @. venv/bin/activate && uvicorn api.app:app --host 0.0.0.0 --port 8000 |
|
|
| dev: |
| @echo "π§ Starting backend with auto-reload..." |
| @echo "π‘ Backend running at http://localhost:8000" |
| @. venv/bin/activate && uvicorn api.app:app --reload |
|
|
| dev-frontend: |
| @echo "βοΈ Starting dashboard dev server..." |
| @echo "π‘ Dashboard running at http://localhost:5173" |
| @cd frontend && npm run dev |
|
|
| dev-docs: |
| @echo "π Starting documentation dev server..." |
| @echo "π‘ Documentation running at http://localhost:3000" |
| @cd website && npm start |
|
|
| start-all: |
| @echo "π Starting all services with tmux..." |
| @chmod +x start-all.sh |
| @./start-all.sh |
|
|
| stop-all: |
| @echo "π Stopping all services..." |
| @chmod +x stop-all.sh |
| @./stop-all.sh |
|
|
| dev-full: |
| @echo "π Use 'make start-all' for better experience with tmux!" |
| @echo "" |
| @echo "Starting backend and frontend (manual)..." |
| @echo "π‘ Backend: http://localhost:8000" |
| @echo "π‘ Dashboard: http://localhost:5173" |
| @echo "π‘ Docs: http://localhost:3000 (run 'make dev-docs' in another terminal)" |
| @echo "" |
| @. venv/bin/activate && uvicorn api.app:app --reload & \ |
| cd frontend && npm run dev |
|
|
| deploy-databricks: |
| @echo "βοΈ Deploying to Databricks Apps..." |
| @chmod +x scripts/deploy-databricks-app.sh |
| @./scripts/deploy-databricks-app.sh |
|
|
| docker-up: |
| @echo "Starting Docker containers..." |
| @docker-compose up -d |
| @echo "β Containers started" |
| @echo " API: http://localhost:8000" |
| @echo " Docs: http://localhost:8000/docs" |
|
|
| docker-down: |
| @echo "Stopping Docker containers..." |
| @docker-compose down |
| @echo "β Containers stopped" |
|
|
| example: |
| @echo "Running example workflow..." |
| @. venv/bin/activate && python examples/example_workflow.py |
|
|
| heatmap: |
| @echo "Generating example heatmap..." |
| @. venv/bin/activate && python main.py generate-heatmap --output example_heatmap.html |
| @echo "β Heatmap saved to example_heatmap.html" |
|
|
| init: |
| @echo "Initializing system..." |
| @. venv/bin/activate && python main.py init |
|
|
| status: |
| @echo "Checking system status..." |
| @. venv/bin/activate && python main.py status |
|
|
| format: |
| @echo "Formatting code..." |
| @. venv/bin/activate && black . |
| @. venv/bin/activate && ruff check . --fix |
| @echo "β Code formatted" |
|
|
| lint: |
| @echo "Linting code..." |
| @. venv/bin/activate && ruff check . |
| @. venv/bin/activate && mypy agents/ pipeline/ visualization/ api/ |
|
|