forked from aio-libs-abandoned/aioredis-py
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
67 lines (47 loc) · 1.16 KB
/
Makefile
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
PYTHON ?= python3
PYTEST ?= pytest
MYPY ?= mypy
# Python implementation
PYTHON_IMPL = $(shell $(PYTHON) -c "import sys; print(sys.implementation.name)")
EXAMPLES = $(sort $(wildcard docs/examples/*.py docs/examples/*/*.py))
.PHONY: all lint init-hooks doc spelling test cov dist devel clean mypy
all: aioredis.egg-info lint doc cov
doc: spelling
mkdocs build
spelling:
@echo "Running spelling check"
$(MAKE) -C docs spelling
mypy:
$(MYPY) aioredis --ignore-missing-imports
test:
$(PYTEST)
cov coverage:
$(PYTEST) --cov
dist: clean
$(PYTHON) setup.py sdist bdist_wheel
clean:
-rm -r docs/build
-rm -r build dist aioredis.egg-info
init-hooks:
pip install -U pre-commit
pre-commit install
pre-commit install-hooks
lint: init-hooks
pre-commit run --all-files
devel: aioredis.egg-info init-hooks
pip install -U pip
pip install -U \
-r tests/requirements.txt \
-r docs/requirements.txt \
bumpversion \
wheel
aioredis.egg-info:
pip install -Ue .
examples: $(EXAMPLES)
$(EXAMPLES):
@export REDIS_VERSION="$(redis-cli INFO SERVER | sed -n 2p)"
$(PYTHON) $@
certificate:
$(MAKE) -C tests/ssl
ci-test:
$(PYTEST) --cov --cov-append --cov-report=xml