summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorYu-Jie Lin <livibetter@gmail.com>2013-08-24 22:00:01 +0800
committerYu-Jie Lin <livibetter@gmail.com>2013-08-24 22:00:01 +0800
commit47a373c61d28835552239c20cfd225c76371e980 (patch)
treef9d4c7c9430f1f61f5204abaf8ae2ec164049dfc /Makefile
parenta7122fc4c21f4705236eec0f47dbda3eeb53dbd3 (diff)
downloadsmartypants-47a373c61d28835552239c20cfd225c76371e980.tar.gz
huge changeset for documentation
Now the documentation is generated by Sphinx. Related commands and configurations are also added. Many moved from README.rst to docstrings in the module.
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile26
1 files changed, 25 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index e58fbd2..06b47da 100644
--- a/Makefile
+++ b/Makefile
@@ -15,12 +15,27 @@ VENV_PY3_CMD=virtualenv-python3.2
BUILD_CMD=./setup.py sdist --formats gztar,zip bdist_wininst --plat-name win32
+# ============================================================================
+
build:
$(BUILD_CMD)
upload:
$(BUILD_CMD) upload
+upload_doc: doc
+ $(PY2_CMD) setup.py upload_sphinx
+
+# ============================================================================
+
+doc: smartypants_command.py
+ make -C docs html
+
+smartypants_command.py: smartypants
+ ln -sf smartypants $@
+
+# ============================================================================
+
test: test_pep8 test_pyflakes test_test install_test
test_%:
@@ -40,4 +55,13 @@ $(VENV_PY2_CMD) $(VENV_PY3_CMD):
. $(INSTALL_TEST_DIR)/bin/activate ; type $(SCRIPT)
$(INSTALL_TEST_DIR)/bin/$(SCRIPT) --version
-.PHONY: build upload install_test $(VENV_PY2_CMD) $(VENV_PY3_CMD)
+# ============================================================================
+
+clean:
+ rm -rf *.pyc build dist __pycache__
+ rm smartypants_command.py
+ make -C docs clean
+
+# ============================================================================
+
+.PHONY: build upload doc install_test $(VENV_PY2_CMD) $(VENV_PY3_CMD) clean