OSDN Git Service

Minor cleanup.
[joypy/Thun.git] / Makefile
1 # My make-fu style is old and tired.  I just want to have a few helper commands.
2
3 TESTDIR = ./test00
4 VERSION = 0.1.0
5
6 .PHONY: clean sdist test docs
7
8
9 clean:
10         $(RM) -r Thun.egg-info/ dist/ build/ __pycache__/ $(TESTDIR)
11         find . -name '*.pyc' | xargs $(RM)
12
13 sdist:
14         python ./setup.py sdist
15
16 # In order to support testing the code as installed
17 # create a virtualenv and install the source dist zip there.
18 test: sdist
19         $(RM) -r $(TESTDIR)
20         virtualenv --system-site-packages --never-download $(TESTDIR)
21         . $(TESTDIR)/bin/activate && \
22                 pip install --no-cache-dir --no-index ./dist/Thun-$(VERSION).tar.gz
23         echo "Type: source $(TESTDIR)/bin/activate"
24
25
26 docs:
27         cd ./docs && python -m nbconvert --to html *.ipynb
28         cd ./docs && python -m nbconvert --to markdown *.ipynb