forked from arthurpanhku/DocSentinel
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
31 lines (22 loc) · 887 Bytes
/
Copy pathMakefile
File metadata and controls
31 lines (22 loc) · 887 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
30
31
.PHONY: help install dev test lint format clean run-api all
help: ## Show this help message
@grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-20s\033[0m %s\n", $$1, $$2}'
install: ## Install dependencies
pip install -r requirements.txt
pip install -r requirements-dev.txt
pip install -e .
dev: install ## Install dev dependencies and pre-commit hooks
pre-commit install
test: ## Run tests
pytest
lint: ## Run linting (ruff)
ruff check .
format: ## Format code (ruff)
ruff format .
ruff check --fix .
clean: ## Clean up build artifacts
rm -rf build dist *.egg-info .pytest_cache .ruff_cache .coverage htmlcov
find . -type d -name "__pycache__" -exec rm -rf {} +
run-api: ## Run the FastAPI backend
uvicorn app.main:app --reload --host 0.0.0.0 --port 8000
all: format lint test ## Run format, lint, and test