-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
75 lines (55 loc) · 1.63 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
71
72
73
74
# -*- coding: utf-8; mode: makefile-gmake -*-
all: help-all
include utils/makefile.include
include utils/makefile.python
include utils/makefile.sphinx
include utils/makefile.0
GIT_URL = [email protected]:return42/fspath.git
PYOBJECTS = fspath
DOC = docs
API_DOC = $(DOC)/fspath-api
SLIDES = docs/slides
PHONY += help help-min help-all
help: help-min
@echo ''
@echo 'to get more help: make help-all'
help-min:
@echo ' docs - build documentation'
@echo ' docs-live - autobuild HTML documentation while editing'
@echo ' clean - remove most generated files'
@echo ' rqmts - info about build requirements'
@echo ''
@echo ' test - run *tox* test'
@echo ' install - developer install (./local)'
@echo ' uninstall - uninstall (./local)'
$(Q)$(MAKE) -e -s make-help
help-all: help-min
@echo ''
$(Q)$(MAKE) -e -s docs-help
@echo ''
$(Q)$(MAKE) -e -s python-help
PHONY += install
install: pyenvinstall
PHONY += uninstall
uninstall: pyenvuninstall
PHONY += $(API_DOC) docs docs-live
docs: $(API_DOC) slides
@$(PY_ENV_BIN)/pip install $(PIP_VERBOSE) -e .
$(call cmd,sphinx,html,docs,docs)
docs-live: pyenvinstall $(API_DOC)
$(call cmd,sphinx_autobuild,html,$(DOCS_FOLDER),$(DOCS_FOLDER))
$(API_DOC): pyenvinstall $(PY_ENV)
$(PY_ENV_BIN)/sphinx-apidoc --separate --maxdepth=1 -o $(API_DOC) fspath
rm -f $(API_DOC)/modules.rst
PHONY += slides
slides: pyenvinstall
$(call cmd,sphinx,html,$(SLIDES),$(SLIDES),slides)
PHONY += clean
clean: pyclean docs-clean
@rm -rf ./$(API_DOC)
$(call cmd,common_clean)
PHONY += rqmts
rqmts: msg-python-exe msg-pip-exe
PHONY += test
test: pytest
.PHONY: $(PHONY)