Changes between Version 1 and Version 2 of CustomTicketPrefixPlugin
- Timestamp:
- May 10, 2015, 11:17:01 AM (9 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
CustomTicketPrefixPlugin
v1 v2 5 5 == Description 6 6 7 Specify a ticket like {{{PREFIX:#1234}}} similar to intertrac links. The difference is it will be rendered like normal ticket linkswith the proper hint holding ticket information instead of intertrac information. Closed tickets will be rendered properly as strike through.7 Specify a ticket like {{{PREFIX:#1234}}} similar to intertrac links. The difference is it will be rendered like a normal TracLink {{{#1234}}} with the proper hint holding ticket information instead of intertrac information. Closed tickets will be rendered properly as strike through. 8 8 9 9 This is useful if you have several Trac instances referencing the same repository. By defining different prefixes for each instance it is possible to reference the correct instance in the commit message. For example: … … 37 37 This is a single file plugin. For installation just copy the python file to you plugin directory. 38 38 39 == Example 40 To define a ticket prefix add the following to your ''trac.ini'': 41 42 {{{#!ini 43 [ticket-prefix] 44 prefix = Pre1, Foo, BAR 45 }}} 46 47 As you can see, it's possible to define several prefixes. 48 49 You may now reference any ticket by prepending the ticket with the defined prefix(es). With the given example the following links are all referencing the same ticket and all links are rendered the same way. 50 51 * {{{#1234}}} 52 * {{{Pre1:#1234}}} 53 * {{{Foo:#1234}}} 54 * {{{Bar:#1234}}} 55 56 A closed ticket would be rendered like: 57 * ~~{{{#123}}}~~ 58 * ~~{{{Pre1:#123}}}~~ 59 * ~~{{{Foo:#123}}}~~ 60 * ~~{{{Bar:#123}}}~~ 61 62 63 39 64 == Recent Changes 40 65