-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
29 lines (24 loc) · 851 Bytes
/
Makefile
File metadata and controls
29 lines (24 loc) · 851 Bytes
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
# Video Query - Orchestration Makefile
.PHONY: setup dev build clean
# 1. Setup both Backend and Frontend
setup:
@echo "--- Setting up Backend ---"
@cd backend && chmod +x setup_env.sh && ./setup_env.sh
@echo "--- Setting up Frontend ---"
@cd frontend && npm install
# 2. Run both servers in parallel
# Uses a trap to ensure both processes are killed on Ctrl+C (SIGINT)
dev:
@echo "--- Launching Video Query (Local) ---"
@trap 'kill 0' INT; \
(cd backend && . .venv/bin/activate && python app.py) & \
(cd frontend && npm start)
# 3. Production Build
build:
@echo "--- Building Frontend ---"
@cd frontend && npm run build
# 4. Cleanup temporary files
clean:
@echo "--- Cleaning logs and temp files ---"
@rm -f *.log
@cd backend && python -c "from services.video_processor import VideoProcessor; VideoProcessor().clear_temp_folders()"