Changes between Version 13 and Version 14 of InterTrac
- Timestamp:
- Sep 28, 2005, 12:00:21 PM (19 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
InterTrac
v13 v14 1 1 = InterTrac Extension for TracLinks = 2 2 3 ''This is a proposal for implementing #234'' 4 ''I think it's now ready for testing (see r1912)''3 ''This is a proposal for implementing #234''. 4 ''It's candidate for integration in the trunk, after the 0.9 release (see #2041)'' 5 5 6 6 == Definitions == … … 17 17 18 18 The link is composed by the target environment name, 19 followed by a colon (e.g. {{{trac:}}}),19 followed by a colon (e.g. `trac:`), 20 20 followed by a regular TracLinks, of any flavor. 21 21 22 22 That target environment name is either the real name of the 23 23 environment, or an alias for it. 24 The aliases are defined in {{{trac.ini}}}(see below).24 The aliases are defined in `trac.ini` (see below). 25 25 The prefix is case insensitive. 26 26 … … 28 28 where one can use an alias as an immediate prefix 29 29 for the identifier of a ticket, changeset or report: 30 (e.g. {{{#T234}}}, {{{[T1508]}}}...) 31 That alias must be at most 3 letters long. 30 (e.g. `#T234`, `[T1508]`, `[trac 1508]`, ...) 32 31 33 32 == Examples == … … 35 34 Besides the other environments run by the same server process 36 35 (called ''sibling'' environments), which are automatically detected, 37 (''Note: currently only in {{{tracd}}}''),36 (''Note: currently only in `tracd`''), 38 37 it is necessary to setup a configuration for the InterTrac facility: 39 38 * in order to refer to a remote Trac 40 39 * for defining environment aliases 41 40 42 This is done quite simply in an {{{[intertrac]}}}section43 within the {{{trac.ini}}}file.41 This is done quite simply in an `[intertrac]` section 42 within the `trac.ini` file. 44 43 45 44 Example configuration: … … 48 47 [intertrac] 49 48 ## -- Example of setting up an alias: 50 t .key= trac49 t = trac 51 50 52 51 ## -- Link to an external Trac: … … 60 59 Now, given this configuration, one could create the following links: 61 60 * to the current InterTrac page: 62 * {{{trac:wiki:InterTrac}}}->61 * `trac:wiki:InterTrac` -> 63 62 [http://projects.edgewall.com/trac/wiki/InterTrac trac:wiki:InterTrac] 64 * {{{t:wiki:InterTrac}}}->63 * `t:wiki:InterTrac` -> 65 64 [http://projects.edgewall.com/trac/wiki/InterTrac t:wiki:InterTrac] 66 * Keys are case insensitive: {{{T:wiki:InterTrac}}}->65 * Keys are case insensitive: `T:wiki:InterTrac` -> 67 66 [http://projects.edgewall.com/trac/wiki/InterTrac T:wiki:InterTrac] 68 67 * to the ticket #234: 69 * {{{trac:ticket:234}}}->68 * `trac:ticket:234` -> 70 69 [http://projects.edgewall.com/trac/ticket/234 trac:ticket:234] 71 * {{{trac:#234}}}->70 * `trac:#234` -> 72 71 [http://projects.edgewall.com/trac/ticket/234 trac:#234] 73 * {{{#T234}}}->74 [http://projects.edgewall.com/trac/ ticket/234 #T234]72 * `#T234` -> 73 [http://projects.edgewall.com/trac/search?q=#234 #T234] 75 74 * to the changeset [1912]: 76 * {{{trac:changeset:1912}}}->75 * `trac:changeset:1912` -> 77 76 [http://projects.edgewall.com/trac/changeset/1912 trac:changeset:1912] 78 * {{{trac:[1912]}}} 79 [http://projects.edgewall.com/trac/changeset/1912 trac:[1912]] 80 * {{{[T1912]}}} -> 81 [http://projects.edgewall.com/trac/changeset/1912 [T1912]] 82 {{{ 83 #!comment 84 To wjl@icecavern.net: 85 The link values you modified were actually matching the current implementation: 86 * {{{trac:[1912]}}} 87 [http://projects.edgewall.com/trac/search?q=1912 trac:[1912]] 88 * {{{trac:#234}}} -> 89 [http://projects.edgewall.com/trac/search?q=234 trac:#234] 77 * `trac:[1912]` -> 78 [http:"//projects.edgewall.com/trac/search?q=[1912]" "trac:[1912]"] 79 * `[T1912]` -> 80 [http://projects.edgewall.com/trac/changeset/1912 "[T1912]"] 90 81 91 In short: one can't assume the local Trac knows about all of92 the shortcut syntax used by the remote Trac.93 82 Anything not given as explicit links (intertrac_prefix:module:id) 94 has to beinterpreted by the remote Trac, relying on its quickjump83 is interpreted by the remote Trac, relying on its quickjump 95 84 facility. 96 }}}97 85 98 86 … … 103 91 == Implementation Notes == 104 92 105 Currently, the {{{[intertrac]}}}configuration has to be repeated93 Currently, the `[intertrac]` configuration has to be repeated 106 94 for each Trac environment, but there's work in progress concerning a 107 95 [ticket:1051 centralized trac.ini], which would help greatly here. … … 111 99 source:branches/cboos-dev/intertrac-branch 112 100 113 In particular, [1912] should implement the behavior described 114 in version 9 of this page. 115 116 117 The general idea is that any {{{[a-zA-Z][a-zA-Z0-9]*:}}} prefix, 101 The general idea is that any `[a-zA-Z.+-]+:` prefix, 118 102 followed by anything which is not a space, has to be interpreted as: 119 1. maybe an alias to something else; i tyes, it is dereferenced103 1. maybe an alias to something else; if yes, it is dereferenced 120 104 before going on 121 1. either a link prefix given by an IWikiSyntaxProvider component 122 1. if not found, an environment name (!InterTrac link) 123 1. if not found, an external system name (!InterWiki link) 124 1. if not found, it is left unchanged 125 126 This order enables one to configure Trac for using another 127 ticket system: first disable the {{{[ticket]}}} component 128 and setup a {{{ticket}}} !InterWiki link pointing to the other 129 BugTrackingSystem. 105 1. then, it's maybe a link prefix given by an `IWikiSyntaxProvider` component 106 1. if not, it's maybe an environment name (!InterTrac link) 107 1. if not, it's maybe an !InterWiki link 108 1. if not, it is not a link