Version 4 (modified by 19 years ago) ( diff ) | ,
---|
This page documents the 1.4 (latest stable) release. Documentation for other releases can be found here.
InterTrac Extension for TracLinks
Warning: this is a proposal for implementing #234
Definition
An InterTrac link is used for referring to a Trac object (Wiki page, changeset, ticket, …) located in another Trac environment.
The link is composed by the target environment name, followed by a column
(e.g. trac:
) followed by a regular TracLinks, of any flavor.
There's also an alternative short-hand form, where one can use a 1, 2 or 3 letters key as an immediate prefix for the identifier of a ticket, changeset or report. That key is associated to an environment name in Trac's configuration file.
Example
Besides other local environments, which are automatically detected, it is necessary to setup a configuration for the InterTrac facility:
- in order to refer to a remote Trac
- for defining project keys
This is done quite simply in an [intertrac]
section
within the trac.ini
file.
Example configuration:
... [intertrac] # Link to an external Trac: trac.title = Edgewall's Trac for Trac trac.url = http://projects.edgewall.com/trac # trac.svn = http://repos.edgewall.com/projects/trac # .svn information could be used in the future to support svn:externals... # Example of setting up an alias: t.key = trac
Now, given this configuration, one could create the following links:
- to the current InterTrac page:
trac:wiki:InterTrac
trac:wiki:InterTract:wiki:InterTrac
t:wiki:InterTrac- Keys are case insensitive:
T:wiki:InterTrac
→ T:wiki:InterTrac
- to the ticket #234:
trac:ticket:234
trac:ticket:234trac:#234
trac:#234#T234
#T234
- to the changeset [1508]:
trac:changeset:1508
trac:changeset:1508trac:[1508]
trac:[1508][T1508]
[T1508]
Notes
Currently, the [intertrac]
configuration has to be repeated
for each Trac environment, but there's work in progress concerning a
centralized trac.ini, which would help greatly here.
This idea was first proposed as a patch for #234, and has been implemented in the following branch: source:branches/cboos-dev/intertrac-branch
In particular, [1508] should implement all the behavior described here.