-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
38 lines (22 loc) · 780 Bytes
/
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
PYTHON=python3.8
# ========== Linux (Debian) ==========
# ----- Install -----
install:
$(if $(shell apt-cache search $(PYTHON)), , \
sudo add-apt-repository -y ppa:fkrull/deadsnakes && apt-get update)
sudo apt-get install -y build-essential
sudo apt-get install -y $(PYTHON) $(PYTHON)-dev $(PYTHON)-venv cython
# ----- Virtualenv -----
venv-init:
if [ ! -e "venv/bin/activate" ]; then $(PYTHON) -m venv venv ; fi;
bash -c "source venv/bin/activate && \
pip install --upgrade wheel pip setuptools && \
pip install --upgrade --requirement requirements.txt"
# ----- Update -----
update: venv-init
# ----- Setup -----
setup: install venv-init
# ----- Tests -----
test: update
bash -c "source venv/bin/activate && \
python -m pytest --doctest-modules -v"