Changes between Version 1 and Version 2 of WikiRestructuredTextLinks
- Timestamp:
- 06/03/10 15:59:45 (14 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
WikiRestructuredTextLinks
v1 v2 1 1 = TracLinks in reStructuredText = 2 2 3 This document illustrates how to use the ` :trac:` role in reStructuredText. The page is written like:3 This document illustrates how to use the ``..trac::`` directive in reStructureThe page is written like 4 4 5 5 {{{ 6 6 {{{ 7 7 #!rst 8 8 9 Examples: 9 10 10 * Tickets: :trac:`#1` or :trac:`ticket:1` 11 11 * Ticket comments: :trac:`comment:ticket:1:2` … … 21 21 * A particular line of a specific file revision: :trac:`source:/trunk/COPYING@200#L25` 22 22 23 An explicit label can be specified, separated from the link by a space:24 25 * See :trac:`#1 ticket 1` and the :trac:`source:trunk/COPYING license`.26 23 }}} 27 24 }}} … … 31 28 {{{ 32 29 #!rst 30 33 31 Examples: 34 35 32 * Tickets: :trac:`#1` or :trac:`ticket:1` 36 33 * Ticket comments: :trac:`comment:ticket:1:2` … … 46 43 * A particular line of a specific file revision: :trac:`source:/trunk/COPYING@200#L25` 47 44 48 An explicit label can be specified, separated from the link by a space:49 50 * See :trac:`#1 ticket 1` and the :trac:`source:trunk/COPYING license`.51 45 }}} 52 46 ---- 53 47 54 Note also that any of the above could have been written using substitution references and the `trac::` directive:48 Note also that any of the above could have been written using the alternate syntax for roles: 55 49 {{{ 56 50 {{{ 57 51 #!rst 58 See |ticket123|.59 52 60 .. |ticket123| trac:: ticket:123 this ticket 53 See _`ticket:123` 54 55 .. trac:: ticket:123 Ticket 123 61 56 }}} 62 57 }}} 63 64 This renders as:65 58 ---- 66 59 67 60 {{{ 68 61 #!rst 69 See |ticket123|.70 62 71 .. |ticket123| trac:: ticket:123 this ticket 63 See _`ticket:123` 64 65 .. trac:: ticket:123 Ticket 123 72 66 }}} 67 ---- 68 The above form has the additional benefit of allowing you to specify an explicit label for the link. 73 69 74 70 ----