-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
70 lines (47 loc) · 1.14 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
68
69
70
.DEFAULT_GOAL := build
.PHONY: build publish package coverage test lint docs venv
PROJ_SLUG = alhenaloader
CLI_NAME = alhenaloader
PY_VERSION = 3.6
LINTER = pylint
SHELL = bash
build:
pip install --editable .
run:
$(CLI_NAME) run
submit:
$(CLI_NAME) submit
freeze:
pip freeze > requirements.txt
lint:
$(LINTER) $(PROJ_SLUG)
test: lint
py.test --cov-report term --cov=$(PROJ_SLUG) tests/
quicktest:
py.test --cov-report term --cov=$(PROJ_SLUG) tests/
coverage: lint
py.test --cov-report html --cov=$(PROJ_SLUG) tests/
docs: coverage
mkdir -p docs/source/_static
mkdir -p docs/source/_templates
cd docs && $(MAKE) html
answers:
cd docs && $(MAKE) html
xdg-open docs/build/html/index.html
package: clean docs
python setup.py sdist
publish: package
twine upload dist/*
clean :
rm -rf dist \
rm -rf docs/build \
rm -rf *.egg-info
coverage erase
venv :
python3 -m venv venv
source venv/bin/activate && pip install pip --upgrade --index-url=https://pypi.org/simple
install:
pip install -r requirements.txt
licenses:
pip-licenses --with-url --format=rst \
--ignore-packages $(shell cat .pip-lic-ignore | awk '{$$1=$$1};1')