-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
57 lines (43 loc) · 1.36 KB
/
Copy pathMakefile
File metadata and controls
57 lines (43 loc) · 1.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
UV := uv
PKG := opensecai
.PHONY: setup install run run-dep-scan api codegen lint format typecheck clean help build
## setup: run the system setup script (installs system libraries, Node, Rust, Trivy)
setup:
chmod +x setup.sh
./setup.sh
## install: create venv and install all dependencies from lockfile
install:
$(UV) sync
## run: run the default (dep_scan) agent locally — requires PROJECT env var
run: run-dep-scan
## build: run the unified production build script (compile sidecar + build tauri package)
build:
chmod +x build.sh
./build.sh
run-dev:
cd desktop && ENV=dev npm run tauri dev
## run-dep-scan: run the dep_scan agent via the root shim
run-dep-scan:
$(UV) run main.py
## lint: lint with ruff
lint:
$(UV) run ruff check main.py $(PKG)
## format: format with ruff
format:
$(UV) run ruff format main.py $(PKG)
## typecheck: type-check with pyright
typecheck:
$(UV) run pyright main.py $(PKG)
## api: run the FastAPI sidecar (localhost:8765 by default)
api:
$(UV) run opensecai-api
## codegen: export Pydantic schemas → schemas-export/ and generate TS types
codegen:
$(UV) run scripts/export_schemas.py
cd desktop && npx json-schema-to-typescript schemas-export/ --out src/api/types
## clean: remove venv and cached files
clean:
rm -rf .venv __pycache__ *.pyc
## help: list available targets
help:
@grep -E '^## ' Makefile | sed 's/## / /'