forked from justincasher/lean-explore
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathMakefile
More file actions
69 lines (56 loc) · 1.97 KB
/
Copy pathMakefile
File metadata and controls
69 lines (56 loc) · 1.97 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
64
65
66
67
68
.PHONY: help install lint format test test-fast test-integration test-external test-all clean docs docs-serve docs-build
help:
@echo "LeanExplore Development Commands"
@echo "================================="
@echo "make install Install package in editable mode with dev dependencies"
@echo "make lint Run ruff linter"
@echo "make format Run ruff formatter"
@echo "make test Run tests with coverage (excludes slow, integration, external)"
@echo "make test-fast Run only fast tests (excludes slow, integration, external)"
@echo "make test-integration Run only integration tests"
@echo "make test-external Run only external tests"
@echo "make test-all Run all tests including slow, integration, and external"
@echo "make docs Build documentation"
@echo "make docs-serve Serve documentation locally (with auto-reload)"
@echo "make clean Remove cache and build artifacts"
install:
pip install -e ".[dev]"
@if [ -f .pre-commit-config.yaml ] || [ -f .pre-commit-config.yml ]; then \
pre-commit install; \
fi
@if [ -f CONTRIBUTING.md ]; then \
cp CONTRIBUTING.md AGENTS.md; \
cp CONTRIBUTING.md CLAUDE.md; \
fi
lint:
ruff check .
format:
ruff format .
test:
pytest --cov=lean_explore --cov-report=term-missing --cov-report=html -v \
-m "not slow and not integration and not external"
test-fast:
pytest -v -m "not slow and not integration and not external"
test-integration:
pytest -v -m "integration" || [ $$? -eq 5 ]
test-external:
pytest -v -m "external" || [ $$? -eq 5 ]
test-all:
pytest --cov=lean_explore --cov-report=term-missing --cov-report=html -v
docs:
pip install -e ".[docs]"
mkdocs build
docs-serve:
pip install -e ".[docs]"
mkdocs serve
clean:
rm -rf build/
rm -rf dist/
rm -rf *.egg-info
rm -rf .pytest_cache
rm -rf .ruff_cache
rm -rf htmlcov/
rm -rf .coverage
rm -rf site/
find . -type d -name __pycache__ -exec rm -rf {} +
find . -type f -name "*.pyc" -delete