-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmakefile
55 lines (37 loc) · 912 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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
PYTHON_VERSION=3
PACKAGE=models
VENV=.venv
SHELL=/bin/bash
PIP=$(VENV)/bin/pip3
# Utility scripts to prettify echo outputs
bold := \033[1m
clr := \033[0m
.PHONY: bootstrap
bootstrap: venv develop
.PHONY: clean
clean:
@echo '$(bold)Clean up old virtualenv and cache$(sgr0)'
rm -rf $(VENV) $(PACKAGE).egg-info .pytest_cache
.PHONY: venv
venv: clean
@echo '$(bold)Create virtualenv$(sgr0)'
virtualenv -p /usr/bin/python$(PYTHON_VERSION) $(VENV)
$(PIP) install --upgrade pip setuptools
.PHONY: develop
develop:
@echo '$(bold)Install and update requirements$(sgr0)'
$(PIP) install --upgrade .[develop]
$(PIP) install --upgrade .[testing]
$(PIP) install -e .
.PHONY: handles
handles:
$(VENV)/bin/python -m models.handles
.PHONY: ashtray
ashtray:
$(VENV)/bin/python -m models.ashtray
.PHONY: basstrap
basstrap:
$(VENV)/bin/python -m models.basstrap
.PHONY: test
test:
$(VENV)/bin/pytest