-
Notifications
You must be signed in to change notification settings - Fork 7
Expand file tree
/
Copy pathMakefile
More file actions
40 lines (28 loc) · 946 Bytes
/
Makefile
File metadata and controls
40 lines (28 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
PYTHON=python3.9
TEST_CONTEXT=export TEST_ENV=True &&
ENV_DIR=.env_$(PYTHON)
IN_ENV=. $(ENV_DIR)/bin/activate &&
env: $(ENV_DIR)
setup:
$(PYTHON) -m pip install --upgrade pip
$(PYTHON) -m pip install virtualenv
$(PYTHON) -m virtualenv -p $(PYTHON) $(ENV_DIR)
$(IN_ENV) $(PYTHON) -m pip install --upgrade -r requirements.txt
$(IN_ENV) $(PYTHON) -m pip install .
inst:
$(IN_ENV) $(PYTHON) -m pip install .
test_requirements:
$(IN_ENV) $(PYTHON) -m pip install --upgrade -r test_requirements.txt
upload_pip: test build_dist
twine upload --repository eircode dist/*
build_dist: setup
rm -fr dist/
$(IN_ENV) python setup.py sdist bdist_wheel
build: setup
quick_build:
$(IN_ENV) $(PYTHON) -m pip install --editable .
test: build test_requirements quick_test
quick_test:
$(IN_ENV) $(TEST_CONTEXT) nosetests --with-coverage --cover-package=eircode --cover-erase --with-timer
$(IN_ENV) coverage report -m
$(IN_ENV) coverage html