[Checkins] SVN: zc.customdoctests/trunk/ Clean up documentation (ReST errors, typos, etc).

Marius Gedminas cvs-admin at zope.org
Thu Feb 14 11:35:30 UTC 2013


Log message for revision 129398:
  Clean up documentation (ReST errors, typos, etc).
  
  

Changed:
  U   zc.customdoctests/trunk/CHANGES.txt
  U   zc.customdoctests/trunk/setup.py
  U   zc.customdoctests/trunk/src/zc/customdoctests/README.txt
  U   zc.customdoctests/trunk/src/zc/customdoctests/spidermonkey.txt

-=-
Modified: zc.customdoctests/trunk/CHANGES.txt
===================================================================
--- zc.customdoctests/trunk/CHANGES.txt	2013-02-14 11:15:49 UTC (rev 129397)
+++ zc.customdoctests/trunk/CHANGES.txt	2013-02-14 11:35:30 UTC (rev 129398)
@@ -1,6 +1,5 @@
-=======
-CHANGES
-=======
+Changelog
+=========
 
 1.0.1 (unreleased)
 ------------------

Modified: zc.customdoctests/trunk/setup.py
===================================================================
--- zc.customdoctests/trunk/setup.py	2013-02-14 11:15:49 UTC (rev 129397)
+++ zc.customdoctests/trunk/setup.py	2013-02-14 11:35:30 UTC (rev 129398)
@@ -14,20 +14,28 @@
 import os
 from setuptools import setup, find_packages
 
+here = os.path.dirname(__file__)
+
+def read(filename):
+    with open(os.path.join(here, filename)) as f:
+        return f.read()
+
+
 install_requires = ['setuptools']
+
 extras_require = dict(
     test=['zope.testing', 'manuel'],
     js=['python-spidermonkey'],
-    )
+)
 
 setup(
-    name = 'zc.customdoctests',
+    name='zc.customdoctests',
     version='1.0.1.dev0',
     url='http://pypi.python.org/pypi/zc.customdoctests',
-    license = 'ZPL 2.1',
-    description = open('README.txt').read().strip().split('\n')[0],
-    author = 'Jim Fulton',
-    author_email = 'jim at zope.com',
+    license='ZPL 2.1',
+    description=read('README.txt').splitlines(False)[0],
+    author='Jim Fulton',
+    author_email='jim at zope.com',
     classifiers=[
         'Development Status :: 4 - Beta',
         'Intended Audience :: Developers',
@@ -42,27 +50,25 @@
         'Natural Language :: English',
         'Operating System :: OS Independent',
         'Topic :: Software Development',
-        ],
-    long_description=(
-        open('README.txt').read() + '\n\n' +
-        open('CHANGES.txt').read() + '\n\n' +
-        '======================\n' +
-        'Detailed dcoumentation\n' +
-        '======================\n\n' +
-        open(os.path.join(os.path.dirname(__file__),
-                          'src', 'zc', 'customdoctests', 'README.txt')
-             ).read() + '\n\n' +
-        open(os.path.join(os.path.dirname(__file__),
-                          'src', 'zc', 'customdoctests', 'spidermonkey.txt')
-             ).read()
-        ),
+    ],
+    long_description=''.join([
+        read('README.txt'),
+        '\n\n'
+        'Detailed documentation\n'
+        '======================\n\n',
+        read('src/zc/customdoctests/README.txt'),
+        '\n\n',
+        read('src/zc/customdoctests/spidermonkey.txt'),
+        '\n\n',
+        read('CHANGES.txt'),
+    ]),
     packages=find_packages('src'),
-    package_dir = {'': 'src'},
-    namespace_packages = ['zc',],
-    install_requires = install_requires,
-    package_data = {'zc.customdoctests': ['*.txt']},
-    extras_require = extras_require,
-    tests_require = extras_require['test'],
-    test_suite = 'zc.customdoctests.tests.test_suite',
-    zip_safe = False,
-    )
+    package_dir={'': 'src'},
+    namespace_packages=['zc',],
+    install_requires=install_requires,
+    package_data={'zc.customdoctests': ['*.txt']},
+    extras_require=extras_require,
+    tests_require=extras_require['test'],
+    test_suite='zc.customdoctests.tests.test_suite',
+    zip_safe=False,
+)

Modified: zc.customdoctests/trunk/src/zc/customdoctests/README.txt
===================================================================
--- zc.customdoctests/trunk/src/zc/customdoctests/README.txt	2013-02-14 11:15:49 UTC (rev 129397)
+++ zc.customdoctests/trunk/src/zc/customdoctests/README.txt	2013-02-14 11:35:30 UTC (rev 129398)
@@ -1,5 +1,5 @@
 Custom doctest parsers
-======================
+----------------------
 
 zc.customdoctests provides a little bit of help with creating custom
 doctest parsers that work pretty muct like regular doctests, but that
@@ -9,7 +9,7 @@
 ps1
    The first-line prompt, which defaultd to ``'>>>'``.
 
-   This must be a regular expression that matches exact;y 3 characters.
+   This must be a regular expression that matches exactly 3 characters.
 
    (Note that you can't override the second-line prompt.)
 

Modified: zc.customdoctests/trunk/src/zc/customdoctests/spidermonkey.txt
===================================================================
--- zc.customdoctests/trunk/src/zc/customdoctests/spidermonkey.txt	2013-02-14 11:15:49 UTC (rev 129397)
+++ zc.customdoctests/trunk/src/zc/customdoctests/spidermonkey.txt	2013-02-14 11:35:30 UTC (rev 129398)
@@ -1,27 +1,25 @@
 Javascript and Python-Spidermonkey support
-==========================================
+------------------------------------------
 
-This file shows some examples of using spidermonkey APIs in doctests.
+.. This file shows some examples of using spidermonkey APIs in doctests.
 
 To wire this up, you'd use something like::
 
    import doctest, zc.customdoctests.js
 
    test_suite = doctest.DocTestSuite(
-       parser = zc.customdoctests.js.parser,
-       setUp = zc.customdoctests.js.spidermonkeySetUp,
-       )
+       parser=zc.customdoctests.js.parser,
+       setUp=zc.customdoctests.js.spidermonkeySetUp)
 
 Or, with manuel::
 
     test_suite = manuel.testing.TestSuite(
-            manuel.doctest.Manuel(parser=zc.customdoctests.js.parser) +
-            manuel.doctest.Manuel(parser=zc.customdoctests.js.eq_parser) +
-            manuel.doctest.Manuel() +
-            manuel.capture.Manuel(),
-            'spidermonkey.txt',
-            setUp=zc.customdoctests.js.spidermonkeySetUp)
-            )
+        manuel.doctest.Manuel(parser=zc.customdoctests.js.parser) +
+        manuel.doctest.Manuel(parser=zc.customdoctests.js.eq_parser) +
+        manuel.doctest.Manuel() +
+        manuel.capture.Manuel(),
+        'spidermonkey.txt',
+        setUp=zc.customdoctests.js.spidermonkeySetUp)
 
 Note that zc.customdoctests doesn't require spidermonkey, so you need
 to install spidermonkey seperately if you want to use it.
@@ -29,7 +27,7 @@
 An advantage of using manuel is that you can use multiple parsers in
 the same document.  In the example, above, 2 javascript example
 syntaxes (described below) as well as the standard doctest syntax are
-supported.  This document is run with manuel to allow all  3 syntaxes.
+supported.  This document is run with manuel to allow all 3 syntaxes.
 
 For the rest of this document, we'll show examples of JavaScript
 doctests as well as helper APIs used to support JavaScript and to



More information about the checkins mailing list