diff --git a/doc/source/conf.py b/doc/source/conf.py index 9eac01e..7816277 100644 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -26,7 +26,7 @@ sys.path.insert(0, os.path.abspath('../..')) # 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.viewcode'] +extensions = ['sphinx.ext.autodoc', 'sphinx.ext.viewcode', 'sphinxcontrib.programoutput'] # Add any paths that contain templates here, relative to this directory. templates_path = ['_templates'] diff --git a/doc/source/index.rst b/doc/source/index.rst index 9d181fc..5b62114 100644 --- a/doc/source/index.rst +++ b/doc/source/index.rst @@ -55,7 +55,7 @@ An example of a Gearman worker:: while True: job = worker.getJob() - job.sendWorkComplete(job.arguments.reverse()) + job.sendWorkComplete(job.arguments[::-1]) SSL Connections --------------- @@ -156,10 +156,8 @@ AdminRequest Objects Server Usage ------------ +.. program-output:: geard --help -A simple Gearman server is provided for convenience in unit testing, -but is not designed for production use at scale. It takes no -parameters other than the port number on which to listen. Server Objects ^^^^^^^^^^^^^^ diff --git a/test-requirements.txt b/test-requirements.txt index 6b80556..4dab357 100644 --- a/test-requirements.txt +++ b/test-requirements.txt @@ -8,3 +8,4 @@ testrepository>=0.0.13 testresources testscenarios testtools>=0.9.27 +sphinxcontrib-programoutput