Syntax Highlighting

If you have Pygments installed, it’s possible to highlight code in ReStructuredText and Markdown articles.


To highlight syntax in ReStructuredText articles, use the “sourcecode” directive:

.. sourcecode:: python

    print "hello!"


The CodeHilite extension is used to highlight syntax in Markdown articles (its included in the markdown package and installed by default):

print "hello!"

Project Versions

Table Of Contents

Previous topic

Directory Structure

Next topic


This Page