7 | | Mail2trac provides : |
8 | | * a Trac-admin command, a bash script (mail2tracAdmin) calling trac-admin |
9 | | * an extension point that allows email messages to be handled by Trac plugins other than mail2trac. |
10 | | |
11 | | The bash script, `mail2tracAdmin` may be called by an [wikipedia:Mail_transfer_agent MTA], for example [http://www.postfix.org/ postfix]. |
12 | | |
13 | | It will open a Trac environment and run through each enabled [source:mailtotracplugin/0.12/plugin/mail2trac/interface.py IEmailHandler] and executes its `invoke()` method if its `match()` method returns `True`. |
14 | | If invoke returns an [http://docs.python.org/library/email email] message, then subsequent `IEmailHandler`s will also process the message. If `None` is returned, then the message is consumed and execution stops. |
15 | | |
16 | | To enable the plugin for `postfix`, add an appropriate line to the aliases file, usually `/etc/aliases` or `/etc/postfix/aliases` and then refreshing the aliases database, see [http://www.postfix.org/aliases.5.html man aliases]. |
17 | | |
18 | | The `mail2tracAdmin` script takes as argument the path to the project environment. The incoming email address should be specified in the `trac.ini` file: |
| 7 | This plugin handles incoming emails within Trac, by parsing and displaying its contents on a Trac ticket. This is useful for software development teams who communicate via email on a topic and want to automatically create a ticket by sending for example a summary to a specified Trac address without the need to enter Trac and create a new ticket there. Attachments are also included in the ticket. A fully worked out basic example is given below. |
| 8 | |
| 9 | Specifically Mail2trac provides: |
| 10 | * a shell script `mail2tracAdmin` that calls `trac-admin` |
| 11 | * an extension point that allows email messages to be handled by other Trac plugins. |
| 12 | |
| 13 | The shell script `mail2tracAdmin` may be called by an [wikipedia:Mail_transfer_agent MTA], for example [http://www.postfix.org/ postfix]. It will open a Trac environment and run through each enabled [source:mailtotracplugin/0.12/plugin/mail2trac/interface.py IEmailHandler] and execute its `invoke()` method if its `match()` method returns `True`. |
| 14 | * If `invoke` returns an [http://docs.python.org/library/email email] message, then subsequent `IEmailHandler`s will also process the message. |
| 15 | * If `None` is returned, then the message is consumed and execution stops. |
| 16 | |
| 17 | To enable the plugin for `postfix`, add an appropriate line to the aliases file, usually `/etc/aliases` or `/etc/postfix/aliases` and then refreshing the `aliases` database, see [http://www.postfix.org/aliases.5.html man aliases]. |
| 18 | |
| 19 | The `mail2tracAdmin` script takes the path to the project environment as argument. The incoming email address should be specified in the `trac.ini` file: |
44 | | * the Trac address must be correctly configured (Mr Obvious). |
45 | | * you must have declared your mail address in your user preferences. |
46 | | * have the correct permission according what you intend to do. |
47 | | * the unix user launching the mail2tracAdmin should have permission on the Trac files, even file creation for attachment. |
| 45 | * the Trac address must be correctly configured. |
| 46 | * the mail address must have been declared in your user preferences. |
| 47 | * have the correct permissions set and according to what you intend to do. |
| 48 | * the UNIX user launching `mail2tracAdmin` should have permission on the Trac files, even file creation for attachment. |