diff options
author | Ned Batchelder <ned@nedbatchelder.com> | 2011-06-05 10:09:21 -0400 |
---|---|---|
committer | Ned Batchelder <ned@nedbatchelder.com> | 2011-06-05 10:09:21 -0400 |
commit | 23d965aee6ac35d85fb38b061440f8d9931ee443 (patch) | |
tree | 0eebf7fa1f1b7e61dde3339c05fe5314b6418d38 | |
parent | c005acc51bf72905d68e93a9b62ed3b67e86ec4d (diff) | |
download | python-coveragepy-git-23d965aee6ac35d85fb38b061440f8d9931ee443.tar.gz |
Add some beta-specific stuff to the home page.
-rw-r--r-- | Makefile | 2 | ||||
-rw-r--r-- | doc/conf.py | 12 | ||||
-rw-r--r-- | doc/index.rst | 33 | ||||
-rw-r--r-- | howto.txt | 15 |
4 files changed, 48 insertions, 14 deletions
@@ -89,3 +89,5 @@ publish: px publishbeta: px rm -f $(WEBHOME)/beta/*.px cp doc/_build/px/*.px $(WEBHOME)/beta + rm -f $(WEBHOME)/sample_html_beta/*.* + cp doc/sample_html_beta/*.* $(WEBHOME)/sample_html_beta diff --git a/doc/conf.py b/doc/conf.py index b8636818..e4dd824d 100644 --- a/doc/conf.py +++ b/doc/conf.py @@ -24,7 +24,7 @@ sys.path.append(os.path.join(os.path.dirname(__file__), "_ext")) # Add any Sphinx extension module names here, as strings. They can be extensions
# coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
-extensions = ['sphinx.ext.autodoc', 'sphinx.ext.todo', 'px_xlator']
+extensions = ['sphinx.ext.autodoc', 'sphinx.ext.todo', 'sphinx.ext.ifconfig', 'px_xlator']
# Add any paths that contain templates here, relative to this directory.
templates_path = ['_templates']
@@ -204,3 +204,13 @@ latex_documents = [ # When auto-doc'ing a class, write the class' docstring and the __init__ docstring
# into the class docs.
autoclass_content = "both"
+
+
+
+
+
+prerelease = bool(max(release).isalpha())
+
+def setup(app):
+ app.add_config_value('prerelease', False, 'env')
+ print "** Prerelease = %r" % prerelease
diff --git a/doc/index.rst b/doc/index.rst index cf595de2..8c9709d8 100644 --- a/doc/index.rst +++ b/doc/index.rst @@ -27,8 +27,19 @@ Coverage measurement is typically used to gauge the effectiveness of tests. It can show which parts of your code are being exercised by tests, and which are not. -The latest version is 3.5b1, released 5 June 2011. -It is supported on Python versions 2.3 through 3.2. +.. ifconfig:: not prerelease + + The latest version is coverage.py 3.4, released 10 September 2010. + It is supported on Python versions 2.3 through 3.2. + +.. ifconfig:: prerelease + + The latest version is coverage.py 3.5b1, released 5 June 2011. + This is a pre-release build. The usual warnings about possible bugs apply. + It is supported on Python versions 2.3 through 3.2. + The latest stable version is coverage.py 3.4, `described here`_. + +.. _described here: http://nedbatchelder.com/code.coverage Quick start @@ -66,11 +77,19 @@ Getting started is easy: $ coverage html - Then visit htmlcov/index.html in your browser, to see a - `report like this`_. + .. ifconfig:: not prerelease + + Then visit htmlcov/index.html in your browser, to see a + `report like this`_. + + .. ifconfig:: prerelease + + Then visit htmlcov/index.html in your browser, to see a + `report like this one`_. .. _coverage page on the Python Package Index: http://pypi.python.org/pypi/coverage .. _report like this: /code/coverage/sample_html/index.html +.. _report like this one: /code/coverage/sample_html_beta/index.html Using coverage.py @@ -106,11 +125,11 @@ Bitbucket also hosts the `code repository`_. .. _Bitbucket issue tracker: http://bitbucket.org/ned/coveragepy/issues .. _code repository: http://bitbucket.org/ned/coveragepy -`I can be reached`__ in a number of ways, I'm happy to answer questions about +`I can be reached`_ in a number of ways. I'm happy to answer questions about using coverage.py. I'm also available hourly for consultation or custom development. -__ http://nedbatchelder.com/site/aboutned.html +.. _I can be reached: http://nedbatchelder.com/site/aboutned.html @@ -123,11 +142,11 @@ More information install cmd config - api source excluding branch subprocess + api faq changes @@ -14,16 +14,19 @@ - Version and date in doc/index.rst - Version and copyright date in doc/conf.py - Version --version output in doc/install.rst + - Generate new sample_html to get the latest, incl footer version number: + cd C:\ned\cog\trunk + rmdir/s/q htmlcov + coverage run --branch --source=cogapp cogapp\test_cogapp.py CogTestsInMemory + coverage html + - IF BETA: + copy/y htmlcov\*.* C:\ned\coverage\trunk\doc\sample_html_beta + - ELSE: + copy/y htmlcov\*.* C:\ned\coverage\trunk\doc\sample_html - 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 --source=cogapp cogapp\test_cogapp.py CogTestsInMemory - coverage html - copy/y htmlcov\*.* C:\ned\coverage\trunk\doc\sample_html - Build and publish docs: $ make px publish - Kits: |