-
Notifications
You must be signed in to change notification settings - Fork 7
Expand file tree
/
Copy pathMakefile
More file actions
56 lines (42 loc) · 946 Bytes
/
Makefile
File metadata and controls
56 lines (42 loc) · 946 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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
PROJ := ofxstatement_fidelity
PYTHON := python3
# "all" should be the safe, verify-everything command
.PHONY: all
all: lint test
# --- Installation & Build ---
# Use editable install (-e) for development so changes take effect immediately
.PHONY: install
install:
pip install -e .[dev]
# Build the distributable package (wheel/sdist) for PyPI
.PHONY: build
build:
$(PYTHON) -m build
# --- Quality Assurance ---
.PHONY: test
test:
pytest
# Run coverage report
.PHONY: coverage
coverage:
pytest --cov=src/ofxstatement
# formatting (black) and static typing (mypy)
.PHONY: lint
lint: black mypy
.PHONY: black
black:
black src tests
.PHONY: mypy
mypy:
mypy src tests
# --- Maintenance ---
.PHONY: clean
clean:
- @ rm -rf build
- @ rm -rf dist
- @ rm -rf src/$(PROJ).egg-info
- @ rm -rf .pytest_cache
- @ rm -f build.log
- @ rm -f install.log
- @ rm -rf .mypy_cache
- @ find . -type d -name "__pycache__" -exec rm -rf {} +