forked from ai-christianson/RA.Aid
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
39 lines (30 loc) · 1.02 KB
/
Copy pathMakefile
File metadata and controls
39 lines (30 loc) · 1.02 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
.PHONY: test setup-dev setup-hooks last-cost help
help:
@echo "Available targets:"
@echo " help - Display this help message"
@echo " test - Run tests with coverage reporting"
@echo " setup-dev - Install development dependencies"
@echo " setup-hooks - Install git pre-commit hooks"
@echo " check - Run code quality checks with ruff"
@echo " fix - Fix code style issues automatically"
@echo " fix-basic - Fix basic code style issues"
@echo " last-cost - Display cost and token usage for the latest session"
test:
# for future consideration append --cov-fail-under=80 to fail test coverage if below 80%
python -m pytest --cov=ra_aid --cov-report=term-missing --cov-report=html
setup-dev:
pip install -e ".[dev]"
setup-hooks: setup-dev
pre-commit install
check:
ruff check
fix:
ruff check . --select I --fix # First sort imports
ruff format .
ruff check --fix
fix-basic:
ruff check --fix
last-cost:
python ra_aid/scripts/cli.py latest
all-costs:
python ra_aid/scripts/cli.py all