-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
63 lines (48 loc) · 1.87 KB
/
Makefile
File metadata and controls
63 lines (48 loc) · 1.87 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
BACKEND_DIR := backend
VIEWER_DIR := viewer
.PHONY: help dev stop backend-setup backend-dev backend-stop backend-restart backend-test backend-example backend-smoke-stream backend-clean viewer-install viewer-dev viewer-build
help:
@echo "Targets:"
@echo " make dev Start backend + viewer together (Ctrl-C to stop both)"
@echo " make stop Stop backend and viewer"
@echo " make backend-setup Create the backend venv, install deps, and seed .env"
@echo " make backend-dev Run the FastAPI backend locally"
@echo " make backend-stop Stop the local FastAPI backend"
@echo " make backend-restart Stop then run the FastAPI backend locally"
@echo " make backend-test Run backend tests"
@echo " make backend-example Run the Vision Agents starter example"
@echo " make backend-smoke-stream Run the mock client against a local backend"
@echo " make backend-clean Remove backend virtualenv and caches"
@echo " make viewer-install Install the React debug viewer dependencies"
@echo " make viewer-dev Run the React debug viewer locally"
@echo " make viewer-build Build the React debug viewer"
dev:
@trap 'kill 0' INT; \
$(MAKE) -C $(BACKEND_DIR) dev & \
(cd $(VIEWER_DIR) && npm run dev) & \
wait
stop:
@$(MAKE) -C $(BACKEND_DIR) stop
@-lsof -ti :5174 | xargs kill 2>/dev/null; true
backend-setup:
@$(MAKE) -C $(BACKEND_DIR) setup
backend-dev:
@$(MAKE) -C $(BACKEND_DIR) dev
backend-stop:
@$(MAKE) -C $(BACKEND_DIR) stop
backend-restart:
@$(MAKE) -C $(BACKEND_DIR) restart
backend-test:
@$(MAKE) -C $(BACKEND_DIR) test
backend-example:
@$(MAKE) -C $(BACKEND_DIR) example
backend-smoke-stream:
@$(MAKE) -C $(BACKEND_DIR) smoke-stream
backend-clean:
@$(MAKE) -C $(BACKEND_DIR) clean
viewer-install:
cd $(VIEWER_DIR) && npm install
viewer-dev:
cd $(VIEWER_DIR) && npm run dev
viewer-build:
cd $(VIEWER_DIR) && npm run build