-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathMakefile
More file actions
40 lines (29 loc) · 1.37 KB
/
Copy pathMakefile
File metadata and controls
40 lines (29 loc) · 1.37 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
SHELL := /bin/bash
BACKEND_DIR := backend
FRONTEND_DIR := frontend
.PHONY: setup backend-install backend-dev frontend-install frontend-dev dev sync-version bump-version seed-parties
setup: backend-install frontend-install sync-version ## Install backend + frontend dependencies
backend-install: ## Install backend Python dependencies via uv
cd $(BACKEND_DIR) && uv sync
frontend-install: ## Install frontend npm dependencies
cd $(FRONTEND_DIR) && npm install
backend-dev: ## Run the FastAPI dev server with auto-reload
cd $(BACKEND_DIR) && uv run fastapi dev
frontend-dev: ## Run the Vite dev server
cd $(FRONTEND_DIR) && npm run dev -- --host
sync-version: ## Copy root VERSION into backend/ for local dev
cp VERSION backend/VERSION
bump-version: ## Set a new version: make bump-version V=1.2.3
@test -n "$(V)" || (echo "Usage: make bump-version V=x.y.z" && exit 1)
@echo "$(V)" > VERSION
@cp VERSION backend/VERSION
@cd frontend && npm version $(V) --no-git-tag-version --allow-same-version > /dev/null
@echo "Version set to $(V)"
seed-parties: ## Seed the parties table with reinsurance market participants
cd $(BACKEND_DIR) && uv run python scripts/seed_parties.py
dev: ## Run backend and frontend dev servers concurrently
@echo "Launching backend and frontend dev servers..."
@trap 'kill 0' INT TERM EXIT; \
$(MAKE) -s backend-dev & \
$(MAKE) -s frontend-dev & \
wait