-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathMakefile
43 lines (32 loc) · 1.12 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
PYTHON = Python3
.PHONY = help set up test run clean
help:
@echo "---------------HELP-----------------"
@echo "To start testing: type make test"
@echo "For code-linting: type make lint"
@echo "To generate coverage: type make coverage"
@echo "To clean up the folder: type make clean"
.PHONY: test
test:
${PYTHON} -m pytest --cov-report term-missing --cov=imageprep --verbose --color=yes
.PHONY: lint
coverage:
${PYTHON} -m flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
${PYTHON} -m coverage-badge -o ./data/logo/coverage.svg
.PHONY: clean
clean:
rm -r *.txt
# =============== Sphinx ==================
SPHINXOPTS ?=
SPHINXBUILD ?= sphinx-build
SOURCEDIR = ./docs
BUILDDIR = ./docs/build
# Put it first so that "make" without argument is like "make help".
#help:
# @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
.PHONY: help Makefile
docs:
# @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
${PYTHON} -m $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
# %: Makefile
# @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)