forked from ccnmtl/django-lti-provider
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
36 lines (30 loc) · 835 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
PY_DIRS=lti_provider
OUTPUT_PATH=ve
VE ?= ./ve
FLAKE8 ?= $(VE)/bin/flake8
REQUIREMENTS ?= test_reqs.txt
SYS_PYTHON ?= python
PIP ?= $(VE)/bin/pip
PY_SENTINAL ?= $(VE)/sentinal
WHEEL_VERSION ?= 0.30.0
VIRTUALENV ?= virtualenv.py
SUPPORT_DIR ?= requirements/virtualenv_support/
MAX_COMPLEXITY ?= 7
INTERFACE ?= localhost
RUNSERVER_PORT ?= 8000
PY_DIRS ?= $(APP)
all: flake8 test
clean:
rm -rf $(OUTPUT_PATH)
$(PY_SENTINAL):
rm -rf $(VE)
$(SYS_PYTHON) $(VIRTUALENV) --extra-search-dir=$(SUPPORT_DIR) $(VE)
$(PIP) install wheel==$(WHEEL_VERSION)
$(PIP) install --use-wheel --no-deps --requirement $(REQUIREMENTS)
touch $@
install-django: $(PY_SENTINAL)
$(PIP) install "$(DJANGO)"
test: $(REQUIREMENTS) $(PY_SENTINAL)
./ve/bin/python runtests.py
flake8: $(PY_SENTINAL)
$(FLAKE8) $(PY_DIRS) --max-complexity=$(MAX_COMPLEXITY)