diff options
author | Ned Batchelder <ned@nedbatchelder.com> | 2010-08-20 16:03:34 -0400 |
---|---|---|
committer | Ned Batchelder <ned@nedbatchelder.com> | 2010-08-20 16:03:34 -0400 |
commit | dc7fb7d0695d8d9de763db264bad317682040167 (patch) | |
tree | 1c07957a3f66a18f12f7c15e27b9cd10d4d33b81 | |
parent | 48f592beb3f85fbe4319b2206f941c6b9a6d0e08 (diff) | |
download | python-coveragepy-git-dc7fb7d0695d8d9de763db264bad317682040167.tar.gz |
Make it possible to have beta docs in a different place than the real docs
-rw-r--r-- | Makefile | 15 | ||||
-rw-r--r-- | doc/_ext/px_xlator.py | 3 | ||||
-rw-r--r-- | doc/conf.py | 4 | ||||
-rw-r--r-- | howto.txt | 22 |
4 files changed, 25 insertions, 19 deletions
@@ -67,27 +67,28 @@ uninstall: SPHINXBUILD = sphinx-build SPHINXOPTS = -a -E doc +SPHINXPXCMD = $(SPHINXBUILD) -b px $(SPHINXOPTS) doc/_build/px WEBHOME = c:/ned/web/stellated/pages/code/coverage px: - $(SPHINXBUILD) -b px $(SPHINXOPTS) doc/_build/px + $(SPHINXPXCMD) + rm doc/_build/px/search.px + +pxbeta: + COVERAGE_DOC_ROOT=/code/coverage/beta/ $(SPHINXPXCMD) rm doc/_build/px/search.px - @echo - @echo "Build finished. The PX files are in doc/_build/px." dochtml: $(SPHINXBUILD) -b html $(SPHINXOPTS) doc/_build/html @echo @echo "Build finished. The HTML pages are in doc/_build/html." -publish: +publish: px rm -f $(WEBHOME)/*.px cp doc/_build/px/*.px $(WEBHOME) rm -f $(WEBHOME)/sample_html/*.* cp doc/sample_html/*.* $(WEBHOME)/sample_html -publishbeta: +publishbeta: pxbeta rm -f $(WEBHOME)/beta/*.px cp doc/_build/px/*.px $(WEBHOME)/beta - rm -f $(WEBHOME)/beta/sample_html/*.* - cp doc/sample_html/*.* $(WEBHOME)/beta/sample_html diff --git a/doc/_ext/px_xlator.py b/doc/_ext/px_xlator.py index 439926c0..dc61a3c2 100644 --- a/doc/_ext/px_xlator.py +++ b/doc/_ext/px_xlator.py @@ -1,6 +1,7 @@ from docutils import nodes
from sphinx.writers.html import SmartyPantsHTMLTranslator
from sphinx.builders.html import StandaloneHTMLBuilder
+import os
def setup(app):
app.add_builder(PxBuilder)
@@ -81,7 +82,7 @@ class PxBuilder(StandaloneHTMLBuilder): self.out_suffix = '.px'
self.link_suffix = '.html'
- self.px_uri = "/code/coverage/"
+ self.px_uri = os.environ.get("COVERAGE_DOC_ROOT") or "/code/coverage/"
def get_target_uri(self, docname, typ=None):
return self.px_uri + docname + self.link_suffix
diff --git a/doc/conf.py b/doc/conf.py index 9c39b852..e8726bd8 100644 --- a/doc/conf.py +++ b/doc/conf.py @@ -47,9 +47,9 @@ copyright = u'2009-2010, Ned Batchelder' # built documents.
#
# The short X.Y version.
-version = '3.3.1'
+version = '3.4'
# The full version, including alpha/beta/rc tags.
-release = '3.3.1'
+release = '3.4 beta'
# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
@@ -13,15 +13,19 @@ - Version, date, and changes in doc/changes.rst - Version and date in doc/index.rst - Version and copyright date in doc/conf.py - - Version --version output in doc/install.py - - Generate new sample_html to get the latest, incl footer version number: - cd C:\ned\cog\trunk - rmdir/s/q htmlcov - coverage run --branch cogapp\test_cogapp.py CogTestsInMemory - coverage html -i - copy/y htmlcov\*.* C:\ned\coverage\trunk\doc\sample_html - - Build and publish docs: - $ make px publish + - Version --version output in doc/install.rst + - IF BETA: + - Build and publish docs: + $ make publishbeta + - ELSE: + - Generate new sample_html to get the latest, incl footer version number: + cd C:\ned\cog\trunk + rmdir/s/q htmlcov + coverage run --branch cogapp\test_cogapp.py CogTestsInMemory + coverage html -i + copy/y htmlcov\*.* C:\ned\coverage\trunk\doc\sample_html + - Build and publish docs: + $ make px publish - Kits: - source .tgz and windows .exe for each Python - $ allkits.cmd |