Changes between Version 8 and Version 9 of InterTrac
- Timestamp:
- Jul 6, 2005, 6:10:21 PM (19 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
InterTrac
v8 v9 1 1 = InterTrac and InterWiki Extension for TracLinks = 2 2 3 ''Warning: this is a proposal for implementing #234, #40 and #1414'' 3 ''This is a proposal for implementing #234, #40 and #1414'' 4 ''I think it's now ready for testing (see r1912)'' 4 5 5 6 == Definitions == … … 28 29 29 30 That target environment name is either the real name of the 30 environment, or an alias for it. 31 environment, or an alias for it. 32 The aliases are defined in {{{trac.ini}}} (see below). 33 The prefix is case insensitive. 31 34 32 35 For convenience, there's also an alternative short-hand form, 33 where one can use a (short) alias as an immediate34 prefixfor the identifier of a ticket, changeset or report:36 where one can use an alias as an immediate prefix 37 for the identifier of a ticket, changeset or report: 35 38 (e.g. {{{#T234}}}, {{{[T1508]}}}...) 39 That alias must be at most 3 letters long. 36 40 37 41 === InterWiki === … … 40 44 }}} 41 45 42 The link is composed by the target Wiki (or system) name,46 The link is composed by the targeted Wiki (or system) name, 43 47 followed by a column (e.g. {{{MeatBall:}}}), 44 followed by a column separated list of identifiers.48 followed by a page specification in the target. 45 49 46 The target Wiki URL is looked up in a page like [http://www.usemod.com/cgi-bin/mb.pl?InterMapTxt MeatBall:InterMapTxt]. 50 The target Wiki URL is looked up in a the InterMapTxt wiki page, 51 modelled after 52 [http://www.usemod.com/cgi-bin/mb.pl?InterMapTxt MeatBall:InterMapTxt]. 47 53 48 Support for #1414: The URL could contain identifier references 49 (e.g. {{{$1}}}, {{{$2}}} ...), 50 that will be replaced by the corresponding identifiers found 51 in the link. 52 If the URL doesn't contain any identifier reference, the identifier 53 is simply appended to the URL (i.e. reverting to the ''traditional'' 54 InterWiki scheme). 55 54 An addition to traditional InterWiki links, where the target 55 is simply ''appended'' to the URL, 56 Trac supports parametric InterWiki URLs: 57 identifiers {{{$1}}}, {{{$2}}}, ... in the URL 58 will be replaced by corresponding arguments from a list 59 made up from the page specification split by the ':' token. 56 60 57 61 == Examples == … … 63 67 it is necessary to setup a configuration for the InterTrac facility: 64 68 * in order to refer to a remote Trac 65 * for defining project keys69 * for defining environment aliases 66 70 67 71 This is done quite simply in an {{{[intertrac]}}} section … … 85 89 Now, given this configuration, one could create the following links: 86 90 * to the current InterTrac page: 87 * {{{trac:wiki:InterTrac}}} trac:wiki:InterTrac 88 * {{{t:wiki:InterTrac}}} t:wiki:InterTrac 89 * Keys are case insensitive: {{{T:wiki:InterTrac}}} → T:wiki:InterTrac 91 * {{{trac:wiki:InterTrac}}} -> 92 [http://projects.edgewall.com/trac/wiki/InterTrac trac:wiki:InterTrac] 93 * {{{t:wiki:InterTrac}}} -> 94 [http://projects.edgewall.com/trac/wiki/InterTrac t:wiki:InterTrac] 95 * Keys are case insensitive: {{{T:wiki:InterTrac}}} -> 96 [http://projects.edgewall.com/trac/wiki/InterTrac T:wiki:InterTrac] 90 97 * to the ticket #234: 91 * {{{trac:ticket:234}}} trac:ticket:234 92 * {{{trac:#234}}} trac:#234 93 * {{{#T234}}} #T234 94 * to the changeset [1508]: 95 * {{{trac:changeset:1508}}} trac:changeset:1508 96 * {{{trac:[1508]}}} trac:[1508] 97 * {{{[T1508]}}} [T1508] 98 * {{{trac:ticket:234}}} -> 99 [http://projects.edgewall.com/trac/ticket/234 trac:ticket:234] 100 * {{{trac:#234}}} -> 101 [http://projects.edgewall.com/trac/search?q=#234 trac:#234] 102 * {{{#T234}}} -> 103 [http://projects.edgewall.com/trac/ticket/234 #T234] 104 * to the changeset [1912]: 105 * {{{trac:changeset:1912}}} -> 106 [http://projects.edgewall.com/trac/changset/1912 trac:changeset:1912] 107 * {{{trac:[1912]}}} 108 [http://projects.edgewall.com/trac/search?q=[1912] trac:[1912]] 109 * {{{[T1912]}}} -> 110 [http://projects.edgewall.com/trac/changeset/1912 [T1508]] 98 111 99 112 === InterWiki === … … 131 144 source:branches/cboos-dev/intertrac-branch 132 145 133 In particular, [1 508] should implement the behavior described134 in version 4of this page.146 In particular, [1912] should implement the behavior described 147 in version 9 of this page. 135 148 136 The InterWiki specification is not yet implemented.137 It is documented together with the InterTrac extension138 because they need to be implemented together, as they139 share a similar syntax.140 149 141 The general idea is that any {{{[a-zA-Z][a-zA-Z0-9]*:}}} prefix 142 has to be interpreted as: 143 1. either a ''module'' name (''module'' being a {{{Component}}} 144 which supports some Wiki syntax) 150 The general idea is that any {{{[a-zA-Z][a-zA-Z0-9]*:}}} prefix, 151 followed by anything which is not a space, has to be interpreted as: 152 1. maybe an alias to something else; it yes, it is dereferenced 153 before going on 154 1. either a link prefix given by an IWikiSyntaxProvider component 145 155 1. if not found, an environment name (!InterTrac link) 146 156 1. if not found, an external system name (!InterWiki link) 157 1. if not found, it is left unchanged 147 158 148 This order enables to configure Trac for using another149 ticket system by disablingthe {{{[ticket]}}} component150 and set tinga {{{ticket}}} !InterWiki link pointing to the other159 This order enables one to configure Trac for using another 160 ticket system: first disable the {{{[ticket]}}} component 161 and setup a {{{ticket}}} !InterWiki link pointing to the other 151 162 BugTrackingSystem.