Changes between Version 4 and Version 5 of WikiRestructuredText
- Timestamp:
- 01/28/15 17:06:11 (10 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
WikiRestructuredText
v4 v5 1 1 = reStructuredText Support in Trac = 2 2 3 Trac supports using ''reStructuredText'' (RST) as an alternative to wiki markup in any contextWikiFormatting is used.3 Trac supports [http://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html reStructuredText (RST)] as an alternative to wiki markup where WikiFormatting is used. 4 4 5 5 From the reStucturedText webpage: 6 6 "''reStructuredText is an easy-to-read, what-you-see-is-what-you-get plaintext markup syntax and parser system. It is useful for in-line program documentation (such as Python docstrings), for quickly creating simple web pages, and for standalone documents. reStructuredText is designed for extensibility for specific application domains. ''" 7 7 8 If you want a file from your Subversion repository be displayed as reStructuredText in Trac's source browser, set `text/x-rst` asvalue for the Subversion property `svn:mime-type`. See [trac:source:/trunk/INSTALL this example].8 If you want a file from your Subversion repository to be displayed as reStructuredText in the Trac source browser, set `text/x-rst` as the value for the Subversion property `svn:mime-type`. See [trac:source:/trunk/INSTALL this example]. 9 9 10 10 === Requirements === 11 Note that to activate RST support in Trac, the python docutils package must be installed. 12 If not already available on your operating system, you can download it at the [http://docutils.sourceforge.net/rst.html RST Website]. 13 14 Install docutils using `easy_install docutils`. Do not use the package manager of your OS (e.g. `apt-get install python-docutils`), because Trac will not find docutils then. 11 To activate RST support in Trac, install the python docutils package: `easy_install docutils`. If not already available on your operating system, you can download it at the [http://docutils.sourceforge.net/rst.html RST Website]. 12 13 Do not use the package manager of your OS, eg `apt-get install python-docutils`, because Trac will not find docutils then. 15 14 16 15 === More information on RST === … … 70 69 For a complete example of all uses of the `:trac:` role, please see WikiRestructuredTextLinks. 71 70 72 73 71 === Syntax highlighting in reStructuredText === 74 72 75 There is a directive for doing TracSyntaxColoring in RST as well. The directive is called 76 code-block 73 There is a directive for doing TracSyntaxColoring in RST as well. The directive is called code-block: 77 74 78 75 ||= Wiki Markup ||= Display || … … 109 106 === Wiki Macros in reStructuredText === 110 107 111 For doing [WikiMacros Wiki Macros] in RST you use the same directive as for syntax highlighting i.e code-block. 108 To enable [WikiMacros Wiki Macros] in RST, you use the same directive as for syntax highlighting, ie code-block: 112 109 113 110 ||= Wiki Markup ||= Display || … … 135 132 }}} 136 133 137 Or a more concise Wiki Macro 134 Or a more concise Wiki Macro-like syntax is also available, using the `:code-block:` role: 138 135 139 136 ||= Wiki Markup ||= Display || … … 156 153 157 154 === Bigger RST Example === 158 The example below should be mostlyself-explanatory:155 The example below should be self-explanatory: 159 156 160 157 ||= Wiki Markup ||= Display ||