blob: b665b0071d9afedd12122b3d8e935e3eb4ada877 (
plain)
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
|
.PHONY: check check-style check-type \
build wheel install clean sphinx-apidoc documentation
PYTHON = python
DOC_OUTPUT = doc.rendered
DESTDIR = /
PREFIX = /usr
build: pyproject.toml $(shell find rainbow_parenthesis -type f -name '*.py')
$(PYTHON) -m build --no-isolation --wheel
install: build
$(PYTHON) -m installer --destdir=$(DESTDIR) --prefix=$(PREFIX) dist/*.whl
check-style:
flake8 rainbow_parenthesis
check-type:
mypy -p rainbow_parenthesis
check: check-style check-type
# Generate some rst files from our source code
sphinx-apidoc:
sphinx-apidoc --separate --force -o doc rainbow_parenthesis
# Build the actual HTML documentation
$(DOC_OUTPUT)/index.html: sphinx-apidoc
sphinx-build -b dirhtml doc $(DOC_OUTPUT)
documentation: sphinx-apidoc
clean:
-rm -r build
-rm -r dist
-rm -r rainbow_parenthesis.egg-info/
|