-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
57 lines (44 loc) · 1.64 KB
/
Makefile
File metadata and controls
57 lines (44 loc) · 1.64 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
all:
@echo "dev_install - Install development dependencies"
@echo "test - Run tests"
@echo "typecheck - Run static type checking only python>=3.10"
@echo "lint - Run static analysis for common problems"
@echo "autoformat - Format all code to a consistent style"
@echo "coverage - Run tests and check the test coverage"
@echo "benchmark - Run a small suite to check performance"
@echo "ci_install - Install dependencies needed for CI"
@echo "fixed_install - Install as a non-editible package like production consumers"
@echo "clean - Delete generated files"
@echo "dist - Build distribution artifacts"
@echo "release - Build distribution and release to PyPI."
test:
python -m pytest
benchmark:
python -m pytest tests/performance*
coverage:
python -m pytest --cov=tuplesumfilter tests --cov-fail-under 90
typecheck:
python -m mypy ./src ./tests
lint:
black --check .
prospector .
autoformat:
black .
clean:
rm -rf build dist src/*.egg-info .tox .pytest_cache pip-wheel-metadata .DS_Store
find src -name '__pycache__' | xargs rm -rf
find tests -name '__pycache__' | xargs rm -rf
dev_install:
python -m pip install -e .[dev]
ci_install:
python -m pip install -e .[ci]
fixed_install:
python -m pip install -e .[ci]
dist: clean
git diff --exit-code # Check for unstaged changes
git diff --exit-code --cached # Check for uncommitted changes
check-manifest
python setup.py sdist bdist_wheel
release: dist
twine upload dist/*.*
.PHONY: all autoformat benchmark ci_install clean coverage dev_install dist fixed_install test typecheck