Skip to content

Instantly share code, notes, and snippets.

@harlowja
Created August 18, 2014 01:45
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save harlowja/eff94ff85b19c2a534ae to your computer and use it in GitHub Desktop.
Save harlowja/eff94ff85b19c2a534ae to your computer and use it in GitHub Desktop.
$ git clone https://github.com/stackforge/doc8
$ cd doc8
$ virtualenv test
$ source test/bin/activate
$ pip install -r requirements.txt
$ python
Python 2.7.6 (default, Mar 22 2014, 22:59:56)
[GCC 4.8.2] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import restructuredtext_lint as rl
>>> path = './doc/source/index.rst'
>>> print([e.message for e in rl.lint_file(path)])
[u'No directive entry for "toctree" in module "docutils.parsers.rst.languages.en".\nTrying "toctree" as canonical directive name.', u'Unknown directive type "toctree".', u'No role entry for "ref" in module "docutils.parsers.rst.languages.en".\nTrying "ref" as canonical role name.', u'Unknown interpreted text role "ref".', u'No role entry for "ref" in module "docutils.parsers.rst.languages.en".\nTrying "ref" as canonical role name.', u'Unknown interpreted text role "ref".', u'No role entry for "ref" in module "docutils.parsers.rst.languages.en".\nTrying "ref" as canonical role name.', u'Unknown interpreted text role "ref".']
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment