# Changeset 38412

Ignore:
Timestamp:
08/29/16 00:35:09 (6 years ago)
Message:

[titan] autoupdate wiki files

Location:
wiki/pages
Files:
115 edited

Unmodified
Removed
• ## wiki/pages/CamelCase

 r37662 = !CamelCase New wiki links are automatically created when concatenating capitalized words, such that for example the word 'Camel' and the word 'Case' concatenated form a link to this CamelCase page. !CamelCase is the original wiki convention for creating hyperlinks, with the additional requirement that the capitals are followed by a lower-case letter; hence “AlabamA” and “ABc” will not be links. == Customizing the Wiki behavior While Trac remains faithful to the original Wiki style, it provides a number of ways to accommodate users with different preferences: * To prevent the creation of a new link of a camel-cased word, prefix with '!': !CamelCase. * To ignore links to missing pages when the link is written using the CamelCase style, that word can instead be replaced by a gray link followed by a question mark. This is useful in cases when CamelCase style is used to name code artifacts like class names and there's no corresponding page for them. This option can be set in ignore_missing_pages in the [wiki:TracIni#wiki-section "[wiki]"] section of TracIni. * There's an option (split_page_names in the  [wiki:TracIni#wiki-section "[wiki]"] section of TracIni) to automatically insert space characters between the words of a CamelCase link when rendering the link. * Creation of explicit Wiki links is also easy, see WikiPageNames for details. * Wiki formatting can be disabled completely in some places, for example when rendering commit log messages. See wiki_format_messages in the [wiki:TracIni#changeset-section "[changeset]"] section of TracIni. See TracIni for more information on the available options. == More information on !CamelCase * http://c2.com/cgi/wiki?WikiCase * http://en.wikipedia.org/wiki/CamelCase ---- See also: WikiPageNames, WikiNewPage, WikiFormatting, TracWiki
• ## wiki/pages/Developer

 r37419 = Welcome to Titannit Projekt = == Infos == ''' Browse Source ''' Browse Source HTTP: [http://sbnc.dyndns.tv/svn /] [http://sbnc.dyndns.tv/svn/crontab /crontab] [http://sbnc.dyndns.tv/svn/image image] [http://sbnc.dyndns.tv/svn/ipk ipk] [http://sbnc.dyndns.tv/svn/titan titan] [http://sbnc.dyndns.tv/svn/tools tools] ''' Changelogs ''' Titan (release): [http://aUtzhFRTzuDFa:JNHZbghnjuz@atemio.dyndns.tv/svn/image-beta/changelog.svn svn-release] [http://aUtzhFRTzuDFa:JNHZbghnjuz@atemio.dyndns.tv/svn/image-beta/changelog.git git-release] [http://aUtzhFRTzuDFa:JNHZbghnjuz@atemio.dyndns.tv/svn/image-beta/changelog.ufs910.titan ufs910-release] [http://aUtzhFRTzuDFa:JNHZbghnjuz@atemio.dyndns.tv/svn/image-beta/changelog.ufs912.titan ufs912-release] [http://aUtzhFRTzuDFa:JNHZbghnjuz@atemio.dyndns.tv/svn/image-beta/changelog.ufs922.titan ufs922-release] [http://aUtzhFRTzuDFa:JNHZbghnjuz@atemio.dyndns.tv/svn/image-beta/changelog.atemio510.titan atemio510-release] [http://aUtzhFRTzuDFa:JNHZbghnjuz@atemio.dyndns.tv/svn/image-beta/changelog.atemio700.titan atemio700-release] [http://aUtzhFRTzuDFa:JNHZbghnjuz@atemio.dyndns.tv/svn/image-beta/changelog.atemio7000.titan atemio7000-release] [http://aUtzhFRTzuDFa:JNHZbghnjuz@atemio.dyndns.tv/svn/image-beta/changelog.atemio7600.titan atemio7600-release] Titan (beta): [http://aUtzhFRTzuDFa:JNHZbghnjuz@beta.dyndns.tv/svn/image-beta/changelog.svn svn-beta] [http://aUtzhFRTzuDFa:JNHZbghnjuz@beta.dyndns.tv/svn/image-beta/changelog.git git-beta] [http://aUtzhFRTzuDFa:JNHZbghnjuz@beta.dyndns.tv/svn/image-beta/changelog.ufs910.titan ufs910-beta] [http://aUtzhFRTzuDFa:JNHZbghnjuz@beta.dyndns.tv/svn/image-beta/changelog.ufs912.titan ufs912-beta] [http://aUtzhFRTzuDFa:JNHZbghnjuz@beta.dyndns.tv/svn/image-beta/changelog.ufs922.titan ufs922-beta] [http://aUtzhFRTzuDFa:JNHZbghnjuz@beta.dyndns.tv/svn/image-beta/changelog.atemio510.titan atemio510-beta] [http://aUtzhFRTzuDFa:JNHZbghnjuz@beta.dyndns.tv/svn/image-beta/changelog.atemio700.titan atemio700-beta] [http://aUtzhFRTzuDFa:JNHZbghnjuz@beta.dyndns.tv/svn/image-beta/changelog.atemio7000.titan atemio7000-beta] [http://aUtzhFRTzuDFa:JNHZbghnjuz@beta.dyndns.tv/svn/image-beta/changelog.atemio7600.titan atemio7600-beta] ''' Build Log Files ''' Images und Plugins (release): [http://aUtzhFRTzuDFa:JNHZbghnjuz@atemio.dyndns.tv/svn/logs logs-release] Images und Plugins (beta): [http://aUtzhFRTzuDFa:JNHZbghnjuz@beta.dyndns.tv/svn/logs logs-beta] ''' Binary and Plugin Libs ''' Titan Binary und Plugins (beta): [http://aUtzhFRTzuDFa:JNHZbghnjuz@beta.dyndns.tv/svn/build binarys-libs-beta] ''' TPK Files ''' Images (release): [http://aUtzhFRTzuDFa:JNHZbghnjuz@atemio.dyndns.tv/svn/tpk tpk-release] Images (beta): [http://aUtzhFRTzuDFa:JNHZbghnjuz@beta.dyndns.tv/svn/tpk tpk-beta] ''' Images ''' Images (release): [http://atemio.dyndns.tv/svn/image images] Images (beta): [http://aUtzhFRTzuDFa:JNHZbghnjuz@beta.dyndns.tv/svn/image-beta images] Images (public-beta-images): [http://aUtzhFRTzuDFa:JNHZbghnjuz@titannit.dyndns.tv/public-beta-images images] == Titan Binary / Plugins Testen == ''' Wichtig ''' Um die titan.cfg bearbeiten zu können muss man erstmal titan stoppen. Das geht per Telnet. mipsel: init 2 sh4: killall -9 rcS titan um das titan binary oder und die neuen libs (Plugins) zu testen muss in der /mnt/config/titan.cfg sos=1 nopluginversion=1 stehen. ansonsten gibt es Probleme mit der Sicherheit. Und man muss per stick neuinstallieren. ''' Path ''' Titan Binary Path: /usr/local/bin/titan Man kann es auch wo anders ablegen z.b /tmp man muss dann nur eben genau dieses starten. Titan Plugins Path: /var/usr/local/share/titan/plugins/ ''' Telnet/Ftp Zugangsdaten ''' User: root Passwort: keins ''' mipsel debug serial''' gui beenden: init 2 files per ftp austauschen gui starten: init 3 ''' mipsel debug console und serial''' gui beenden beim ersten mal mit: init 2 files per ftp austauschen gui starten: titan /mnt/config/titan.cfg gui beenden nach dem manuellen start: killall -9 titan ''' sh4 debug console und serial ''' killall -9 rcS titan titan /mnt/config/titan.cfg == Plugins Bauen == ''' Vorbereitung ''' im aktuellen tdt git http://gitorious.org/open-duckbox-project-sh4 kann man nun TitanNit Plugins bauen. ich habe mal 2 plugins eingebaut die als beispiel dienen sollen. man kann sich dann seinen stand lokal erweitern und eigene plugins bauen. wer ein frisches git benutzt muss einmal {{{ make yaud-enigma2-nightly }}} durchlaufen lassen danach reicht dann immer ein {{{ make titan-plugins }}} ''' IPKs selber bauen ''' http://www.aaf-digital.info/forum/showthread.php?90505-Externe-TitanNit-Plugins-selber-bauen

• ## wiki/pages/TracBatchModify

 r37567 = Trac Ticket Batch Modification = [[TracGuideToc]] Trac supports modifying a batch of tickets in one request from [TracQuery custom query] results . To perform a batch modification, select the tickets you wish to modify and set the new field values using the section underneath the query results. == List fields The Keywords and Cc fields are treated as lists, where list items can be added and/or removed in addition of replacing the entire list value. All list field controls accept multiple items, such as multiple keywords or cc addresses. == Excluded fields Multi-line text fields are not supported, because no valid use-case has been presented for syncing them across several tickets. That restriction applies to the Description field as well as to any [TracTicketsCustomFields#AvailableFieldTypesandOptions custom field] of type 'textarea'. However, future versions of Trac could support in conjunction with more suitable actions like 'prepend', 'append' or 'search & replace' ([http://trac-hacks.org/ticket/2415 th:#2415]).
• ## wiki/pages/TracBrowser

 r37567 = The Trac Repository Browser [[TracGuideToc]] The Trac repository browser can be used to browse specific revisions of directories and files stored in the repositories associated with the Trac environment. At the top-level of the repository browser is the '''Repository Index''', listing all the configured repositories. Each repository has a name which is used as a path prefix in a "virtual" file hierarchy encompassing all the available repositories. One of the repositories can be configured with an empty name; this is the default repository. When such a default repository is present, its top-level files and directories are also listed, in a '''Default Repository''' section placed before the repository index. If the default repository is the only repository associated with the Trac environment, then the '''Repository Index''' will be omitted. This means that after upgrading a single-repository Trac of version 0.11 (or earlier) to a multi-repository Trac (0.12), the repository browser will look and feel the same, that single repository becoming automatically the "default" repository. Directory entries are displayed in a list with sortable columns. The list entries can be sorted by ''Name'', ''Size'', ''Age'' or ''Author'' by clicking on the column headers. The sort order can be reversed by clicking on a given column header again. The browser can be used to navigate through the directory structure by clicking on the directory names. Clicking on a file name will show the contents of the file. Clicking on the revision number of a file or directory will take you to the TracRevisionLog for that file. Note that there's also a ''Revision Log'' navigation link that will do the same for the path currently being examined. Clicking on the ''diff'' icon after revision number will display the changes made to the files modified in that revision. Clicking on the ''Age'' of the file - will take you to that changeset in the timeline. It's also possible to browse directories or files as they were in history, at any given repository revision. The default behavior is to display the latest revision but another revision number can easily be selected using the ''View revision'' input field at the top of the page. The color bar next to the ''Age'' column gives a visual indication of the age of the last change to a file or directory, following the convention that '''[[span(style=color:#88f,blue)]]''' is oldest and '''[[span(style=color:#f88,red)]]''' is newest, but this can be [TracIni#browser-section configured]. At the top of the browser page, there's a ''Visit'' drop-down menu which you can use to select some interesting places in the repository, for example branches or tags. This is sometimes referred to as the ''browser quickjump'' facility. The precise meaning and content of this menu depends on your repository backend. For Subversion, this list contains by default the top-level trunk directory and sub-directories of the top-level branches and tags directories (/trunk, /branches/*, and /tags/*). This can be [TracIni#svn-section configured] for more advanced cases. If you're using a Javascript enabled browser, you'll be able to expand and collapse directories in-place by clicking on the arrow head at the right side of a directory. Alternatively, the [trac:TracKeys keyboard] can also be used for this: - use j and k to select the next or previous entry, starting with the first - o ('''o'''pen) to toggle between expanded and collapsed state of the selected directory or for visiting the selected file - v ('''v'''iew, '''v'''isit) and , same as above - r can be used to force the '''r'''eload of an already expanded directory - a can be used to directly visit a file in '''a'''nnotate (blame) mode - l to view the '''l'''og for the selected entry If no row has been selected using j or k these keys will operate on the entry under the mouse. For the Subversion backend, some advanced additional features are available: - The svn:needs-lock property will be displayed. - Support for the svn:mergeinfo property showing the merged and eligible information. - Support for browsing the svn:externals property, which can be [TracIni#svn:externals-section configured]. - The svn:mime-type property is used to select the syntax highlighter for rendering the file. For example, setting svn:mime-type to text/html will ensure the file is highlighted as HTML, regardless of the file extension. It also allows selecting the character encoding used in the file content. For example, if the file content is encoded in UTF-8, set svn:mime-type to text/html;charset=utf-8. The charset= specification overrides the default encoding defined in the default_charset option of the [trac] section of [TracIni#trac-section trac.ini]. {{{#!comment MMM: I found this section a bit hard to understand. I changed the first item as I understood that well. but I think the other items could be changed also cboos: in the meantime, I've added the ''advanced'' word as a hint this can be a bit complex... }}} ---- See also: TracGuide, TracChangeset, TracFineGrainedPermissions
• ## wiki/pages/TracCgi

 r37567 = Installing Trac as CGI [[TracGuideToc]] [[PageOutline]] {{{#!div class=important ''Please note that using Trac via CGI is the slowest deployment method available. It is slower than [TracModPython mod_python], [TracFastCgi FastCGI] and even [trac:TracOnWindowsIisAjp IIS/AJP] on Windows.'' }}} CGI script is the entrypoint that web-server calls when a web-request to an application is made. The trac.cgi script can be created using the trac-admin deploy  command which automatically substitutes the required paths, see TracInstall#cgi-bin. Make sure the script is executable by your web server. == Apache web-server configuration In [http://httpd.apache.org/ Apache] there are two ways to run Trac as CGI: 1. Use a ScriptAlias directive that maps an URL to the trac.cgi script (recommended) 1. Copy the trac.cgi file into the directory for CGI executables used by your web server (commonly named cgi-bin). You can also create a symbolic link, but in that case make sure that the FollowSymLinks option is enabled for the cgi-bin directory. To make Trac available at http://yourhost.example.org/trac add ScriptAlias directive to Apache configuration file, changing trac.cgi path to match your installation: {{{#!apache ScriptAlias /trac /path/to/www/trac/cgi-bin/trac.cgi }}} ''Note that this directive requires enabled mod_alias module.'' If you're using Trac with a single project you need to set its location using the TRAC_ENV environment variable: {{{#!apache SetEnv TRAC_ENV "/path/to/projectenv" }}} Or to use multiple projects you can specify their common parent directory using the TRAC_ENV_PARENT_DIR variable: {{{#!apache SetEnv TRAC_ENV_PARENT_DIR "/path/to/project/parent/dir" }}} ''Note that the SetEnv directive requires enabled mod_env module. It is also possible to set TRAC_ENV in trac.cgi. Just add the following code between "try:" and "from trac.web ...":'' {{{#!python import os os.environ['TRAC_ENV'] = "/path/to/projectenv" }}} '' Or for TRAC_ENV_PARENT_DIR: '' {{{#!python import os os.environ['TRAC_ENV_PARENT_DIR'] = "/path/to/project/parent/dir" }}} If you are using the [http://httpd.apache.org/docs/suexec.html Apache suEXEC] feature please see [trac:ApacheSuexec]. On some systems, you ''may'' need to edit the shebang line in the trac.cgi file to point to your real Python installation path. On a Windows system you may need to configure Windows to know how to execute a .cgi file (Explorer -> Tools -> Folder Options -> File Types -> CGI). === Using WSGI You can run a [http://henry.precheur.org/python/how_to_serve_cgi WSGI handler] [http://pythonweb.org/projects/webmodules/doc/0.5.3/html_multipage/lib/example-webserver-web-wsgi-simple-cgi.html under CGI].  You can [wiki:TracModWSGI#Thetrac.wsgiscript write your own application function], or use the deployed trac.wsgi's application. == Mapping Static Resources See TracInstall#MappingStaticResources. == Adding Authentication See TracInstall#ConfiguringAuthentication. ---- See also:  TracGuide, TracInstall, [wiki:TracModWSGI], TracFastCgi, TracModPython
• ## wiki/pages/TracChangeLog

 r37567 [[PageOutline(2-3)]] = Change Log This is a rough list of changes between released versions. To see where Trac is going in future releases, see the [trac:roadmap Roadmap]. == 1.1.x Releases // 1.1.x releases are development releases leading eventually to Trac 1.2. See them as kind of snapshots of [trac:source:trunk]. ** No guarantees of feature and API compatibility is made from one 1.1.x release to the next. // === 1.1.6 //(July 17, 2015)// Trac 1.1.6 contains more than a half dozen minor fixes and enhancements. For more information see the [trac:wiki:TracDev/ApiChanges/1.1 API changes] and the detailed release notes for [[trac:wiki:TracDev/ReleaseNotes/1.1#DevelopmentReleases | 1.1.6]] and [[trac:wiki:TracDev/ReleaseNotes/1.0#MaintenanceReleases | 1.0.7]] (as 1.1.6 contains all the fixes done for 1.0.7). [trac:source:/tags/trac-1.1.6 View Tag] | [trac:milestone:1.1.6 View Milestone] === 1.1.5 //(May 18, 2015)// Highlights of the changes: - Corrected highlighting of unmodified values in //Config// section of the //About Trac// page ([trac:#6551]). - New helper methods on DatabaseManager class for plugins to upgrade the database ([trac:#8172]). - New [notification-subscriber] config section for general configuration of notification subscription defaults and SubscriberList macro ([trac:#11875]). - Removed dependency on ConfigObj for TracFineGrainedPermissions ([trac:#11982]). - Image macro supports InterWiki prefixes ([trac:#12025]). See also the [trac:wiki:TracDev/ApiChanges/1.1 API changes] and the detailed release notes for [[trac:wiki:TracDev/ReleaseNotes/1.1#DevelopmentReleases | 1.1.5]], [[trac:wiki:TracDev/ReleaseNotes/1.0#MaintenanceReleases | 1.0.6]] and [[trac:wiki:TracDev/ReleaseNotes/0.12#MaintenanceReleases | 0.12.7]] (as 1.1.5 contains all the fixes done for 1.0.6 and 0.12.7). [trac:source:/tags/trac-1.1.5 View Tag] | [trac:milestone:1.1.5 View Milestone] === 1.1.4 //(March 24, 2015)// Highlights of the changes: - Performance improvements with MySQL/MariaDB ([trac:#3676]). - Click on //Permissions// Admin page table row toggles all checkboxes in the row ([trac:#11417]). - Configuration sections are written to trac.ini when enabling a component through TracAdmin or the web administration module ([trac:#11437]). - Subscription rules can be reordered by drag and drop ([trac:#11941]). See also the [trac:wiki:TracDev/ApiChanges/1.1 API changes] and the detailed release notes for [[trac:wiki:TracDev/ReleaseNotes/1.1#DevelopmentReleases | 1.1.4]] and [[trac:wiki:TracDev/ReleaseNotes/1.0#MaintenanceReleases | 1.0.4/1.0.5]] (as 1.1.4 contains all the fixes done for 1.0.4 and 1.0.5). [trac:source:/tags/trac-1.1.4 View Tag] | [trac:milestone:1.1.4 View Milestone] === 1.1.3 //(January 13, 2015)// The following list contains highlights of the changes: - The ticket creation step can be configured in the TracWorkflow and the workflow controls are present on the !NewTicket page ([trac:#2045]). - New notification system that can be extended by plugins ([trac:#3517]). - New preferences panel for notification subscriptions ([trac:#4056]). - Wiki page version comments can be edited by users with WIKI_ADMIN ([trac:#6573]). - Improved positioning of //Add Comment// section and //author// field on the ticket form ([trac:#10207]). - The delete confirmation pages warn if attachments will also be deleted ([trac:#11542]). - Removed support for [trac:SilverCity], Enscript and !PhpRenderer syntax highlighters ([trac:#11795]). - Combined //Date & Time// and //Language// preference panels as //Localization// ([trac:#11813]). - Groups and permissions can be used in the workflow set_owner attribute ([trac:#11839]). See also the [trac:wiki:TracDev/ApiChanges/1.1 API changes] and the detailed release notes for [[trac:wiki:TracDev/ReleaseNotes/1.1#DevelopmentReleases | 1.1.3]] and [[trac:wiki:TracDev/ReleaseNotes/1.0#MaintenanceReleases | 1.0.3]] (as 1.1.3 contains all the fixes done for 1.0.3). [trac:source:/tags/trac-1.1.3 View Tag] | [trac:milestone:1.1.3 View Milestone] === 1.1.2 //(October 23, 2014)// The following list contains highlights of the changes: - Dropped support for Python 2.5. Trac can no longer be run on Python 2.5 as incompatible changes have been made in the source code ([trac:#11600]). - The new ticket workflow action may_set_owner is similar to set_owner but the owner defaults to the existing ticket owner rather than the current user ([trac:#10018]). - The new option [ticket] optional_fields specifies ticket select fields that are treated as optional (i.e. an empty value is allowed) ([trac:#10772]). - Line number and row highlighting annotations can be specified for !WikiProcessor code blocks ([trac:#10834]). - The //default handler// can be set as a session preference ([trac:#11597]), and the default value for all users can be set from the //Basic Settings// admin page ([trac:#11519]). - Attachments can't be added to read-only wiki pages ([trac:#11244]). - Tables on the admin pages have a //Select all// checkbox in the header ([trac:#10994]). - Submit buttons are disabled if the required items are not selected ([trac:#11056]). - The Admin //Permissions// page has a //Copy Permissions// form for copying permissions between users and groups ([trac:#11099]). - The new option [milestone] default_retarget_to determines the default milestone for retargeting tickets when a milestone is deleted or closed, and can be specified from the //Milestone// admin page ([trac:#10010]). - The //retarget// select is not shown when closing or deleting a milestone which has no tickets associated with it ([trac:#11366]). - //Clear default// buttons allow the ticket system default values (e.g. default_milestone, default_version) to be cleared through the corresponding admin pages ([trac:#10772], [trac:#11300]). - The TitleIndex macro supports relative path prefixes when used on wiki pages ([trac:#11455]). - [trac:CommitTicketUpdater] will recognize a ticket reference that includes a trailing #comment:N or #comment:description ([trac:#11622]). - The //Tickets// column of the milestone table on the //Milestone// admin page contains links to the query page showing all tickets associated with the milestone, grouped by status ([trac:#11661]). - Authz policy can be used to restrict access to the //Report List// page using the resource id -1 ([trac:#11697]). See also the [trac:wiki:TracDev/ApiChanges/1.1 API changes] and the detailed release notes for [[trac:wiki:TracDev/ReleaseNotes/1.1#DevelopmentReleases | 1.1.2]], [[trac:wiki:TracDev/ReleaseNotes/1.0#MaintenanceReleases | 1.0.2]] and [[trac:wiki:TracDev/ReleaseNotes/0.12#MaintenanceReleases | 0.12.6]] (as 1.1.2 contains all the fixes done for 1.0.2 and 0.12.6). [trac:source:/tags/trac-1.1.2 View Tag] | [trac:milestone:1.1.2 View Milestone] === 1.1.1 //(February 3, 2013)// Trac 1.1.1 starts the 1.1.x development line leading to 1.2 with some new features and a few not-so-disruptive changes. The following list contains only a few highlights: - Added support for custom ticket fields of type time ([trac:#1942]) - In new tickets, custom time ticket fields may default to an absolute or relative date / time ([trac:#10853]) - In TracBatchModify, custom time ticket fields can be changed with a date(time)picker popup control ([trac:#10854]) - Optionally display the component of tickets in their timeline entries ([timeline] ticket_show_component setting) ([trac:#10885]) - Fixed batch modification when no fields are changed ([trac:#10924]) - Dynamic variables can be used in the report title and description ([trac:#10979]) - jQuery upgraded to 1.8.3, jQuery UI upgraded to 1.9.2 and jQuery UI Timepicker upgraded to 1.1.1 ([trac:#10976]) - Dropped support for Python 2.5, either Python 2.6 or Python 2.7 is required //(well, as it happens, 2.5 //still// works, that's a bug ;-) )// See also the [trac:wiki:TracDev/ApiChanges/1.1 API changes] and the detailed release notes for [[trac:wiki:TracDev/ReleaseNotes/1.1#DevelopmentReleases | 1.1.1]], [[trac:wiki:TracDev/ReleaseNotes/1.0#MaintenanceReleases | 1.0.1]] and [[trac:wiki:TracDev/ReleaseNotes/0.12#MaintenanceReleases | 0.12.5]] (as 1.1.1 contains all the fixes done for 1.0.1 and 0.12.5). [trac:source:/tags/trac-1.1.1 View Tag] | [trac:milestone:1.1.1 View Milestone] == 1.0.x Releases == === 1.0.7 //(July 17, 2015)// Trac 1.0.7 contains more than a dozen minor fixes and enhancements, including the following highlights: - Custom svn:keywords definitions are expanded in Subversion 1.8 and later ([trac:#11364]). - Fixed MySQL performance regression in query with custom fields ([trac:#12113]). See the detailed release notes for [[trac:wiki:TracDev/ReleaseNotes/1.0#MaintenanceReleases | 1.0.7]]. [trac:source:/tags/trac-1.0.7 View Tag] | [trac:milestone:1.0.7 View Milestone] === 1.0.6 //(May 20, 2015)// Trac 1.0.6 provides more than 20 fixes and enhancements. The following are some highlights: - Hash changeset ids and branch names can be used in revision ranges ([trac:#11050]) - Improved rendering performance using chunked response when [trac] use_chunked_encoding is True ([trac:#11802]) - Improved performance of Git repositories ([trac:#11971]). - Header to send when [trac] use_xsendfile is True can be specified through the option [trac] xsendfile_header. X-Sendfile is supported in Nginx by specifying X-Accel-Redirect for the header ([trac:#11981]). - Symbolic link can be used for conf/trac.ini in environment directory ([trac:#12000]). - Hyphen character can be used in !WikiProcessor parameter name ([trac:#12023]). See the detailed release notes for [[trac:wiki:TracDev/ReleaseNotes/1.0#MaintenanceReleases | 1.0.6]] and [[trac:wiki:TracDev/ReleaseNotes/0.12#MaintenanceReleases | 0.12.7]] (as 1.0.6 contains all the changes in 0.12.7). [trac:source:/tags/trac-1.0.6 View Tag] | [trac:milestone:1.0.6 View Milestone] === 1.0.5 //(March 24, 2015)// Trac 1.0.5 provides several fixes. The following are some highlights: - Images are not rendered in the timeline ([trac:#10751]). - Git tags are shown in the browser view ([trac:#11964]). - Added support for journal_mode and synchronous pragmas in sqlite: database connection string ([trac:#11967]). See the detailed release notes for [[trac:wiki:TracDev/ReleaseNotes/1.0#MaintenanceReleases | 1.0.5]]. [trac:source:/tags/trac-1.0.5 View Tag] | [trac:milestone:1.0.5 View Milestone] === 1.0.4 //(February 8, 2015)// Trac 1.0.4 contains a few fixes, including a fix for a regression in 1.0.3. - Workflow action labels were not displayed unless name attribute was explicitly defined ([trac:#11930]). See the detailed release notes for [[trac:wiki:TracDev/ReleaseNotes/1.0#MaintenanceReleases | 1.0.4]]. [trac:source:/tags/trac-1.0.4 View Tag] | [trac:milestone:1.0.4 View Milestone] === 1.0.3 //(January 13, 2015)// Trac 1.0.3 is a maintenance release containing numerous fixes and minor enhancements. The following are a few of the highlights: The following list contains only a few highlights: - Notification is sent when adding an attachment to a ticket ([trac:#2259]). - Stylesheets and scripts are loaded during autopreview, resulting in proper syntax highlighting when code WikiProcessors are added ([trac:#10470]) and display of Workflow graphs without explicit autopreview ([trac:#10674]). - Merge changesets are shown as differences against first parent, resulting in less noisy changesets ([trac:#10740]). - Pygments 2.0 is supported ([trac:#11796]). - Fixed error when completing the initenv TracAdmin command ([trac:#11797]). - Performance improvement on systems with many thousands of authenticated users due to caching of Environment.get_known_users ([trac:#11868]). - Distribution metadata of wheel package is supported and displayed on the About page ([trac:#11877]). - … and more than 3 dozen total fixes! See the detailed release notes for [[trac:wiki:TracDev/ReleaseNotes/1.0#MaintenanceReleases | 1.0.3]]. [trac:source:/tags/trac-1.0.3 View Tag] | [trac:milestone:1.0.3 View Milestone] === 1.0.2 //(October 23, 2014)// Trac 1.0.2 contains a number of bug fixes and minor enhancements, as well as a major update for many translations. The following list contains only a few highlights: - Subversion keywords are expanded and EOL substitutions made when viewing a file in the repository browser and when downloading a file ([trac:#717]). - Notification email is sent to the old owner when a ticket is reassigned ([trac:#2311]). - Ticket change history is updated when renaming and deleting a milestone, and when retargeting tickets to another milestone ([trac:#4582], [trac:#5658]). - Numerous fixes for the Authz permissions policy in the browser/repository ([trac:#10961], [trac:#11646]), wiki ([trac:#8976], [trac:#11067]), admin ([trac:#11069]) and report ([trac:#11176]) realms. - Multiple forms submits are disallowed ([trac:#10138]). - ConfigurationError is raised if any of the permission_policies can't be loaded, preventing possible information leakage due to internal and installation errors ([trac:#10285]). - Wiki toolbars can be disabled through a configuration setting ([trac:#10837]) - The number of entries in a table is shown next to heading on applicable admin pages ([trac:#11027]). - //Cancel// buttons are consistently located on all pages ([trac:#11076]). - Focus is placed on a text element when an edit page is loaded ([trac:#11084]). - The //Edit conflict// and //Merge// warning messages are always visible in side-by-side edit mode ([trac:#11102]). - Improvements to the layout of the Report ([trac:#11106], [trac:#11664]) and Ticket pages ([trac:#11471]). - Genshi 0.7 compatibility ([trac:#11218]). - Numerous minor fixes for Git repository support. - … and more than a hundred more fixes! See the detailed release notes for [[trac:wiki:TracDev/ReleaseNotes/1.0#MaintenanceReleases | 1.0.2]] and [[trac:wiki:TracDev/ReleaseNotes/0.12#MaintenanceReleases | 0.12.6]] (as 1.0.2 contains all the fixes done for 0.12.6). [trac:source:/tags/trac-1.0.2 View Tag] | [trac:milestone:1.0.2 View Milestone] === 1.0.1 //(February 1, 2013)// Trac 1.0.1 contains a number of bug fixes and minor enhancements, as well as a major update for many translations. The following list contains only a few highlights: - Fix zip source download for large directories in Subversion repositories ([trac:#10840]) - Performance improvement for the Roadmap, by caching milestone properties ([trac:#10879]) - Added a ''select all'' checkbox to table of components for each plugin on the Plugins admin panel ([trac:#9609]) - Restore the ''Modify'' link at the top of the ticket page, as it was in Trac 0.12 ([trac:#10856]) - ListOption keeps values other than empty string and None in raw list as default ([trac:#10541]) - Prevent possibility of multiple identical info or warning messages being presented to the user ([trac:#10987]) - The !BatchModify select-all checkboxes are toggled with tri-state behavior when the ticket checkboxes are toggled ([trac:#10992]) - Update the ticket changetime to the current time when deleting a ticket comment ([trac:#10486]) See the detailed release notes for [[trac:wiki:TracDev/ReleaseNotes/1.0#MaintenanceReleases | 1.0.1]] and [[trac:wiki:TracDev/ReleaseNotes/0.12#MaintenanceReleases | 0.12.5]] (as 1.0.1 contains all the fixes done for 0.12.5). [trac:source:/tags/trac-1.0.1 View Tag] | [trac:milestone:1.0.1 View Milestone] === '''1.0 'Cell' ''' //(September 7, 2012)// Trac 1.0 is a major release adding refreshed user interface and improved DVCS repository support as the most visible changes. The following list contains only a few highlights: - The default theme looks more modern, especially on recent browsers (no effort has been made to make it look better on older browsers like IE6 or 7) - The [TH:GitPlugin] has been donated by Herbert Valerio Riedel to the Trac project (many thanks!) and is now maintained here as an optional component - As a consequence, the Subversion support has been moved below tracopt.versioncontrol as well - The Git and Mercurial log view feature a visualization of the branching structure - Usability improvements for the tickets, with a better support for conflict detection and resolution - Integration of the [TH:BatchModifyPlugin], contributed by Brian Meeker (many thanks!) and is now maintained there as a default component - jQuery/UI integration, featuring a date picker for date fields - Improved integration with Pygments syntax highlighting - ... and numerous smaller features added and bugs fixed since 0.12! See the full list in [trac:wiki:TracDev/ReleaseNotes/1.0 1.0]. [[trac:source:/tags/trac-1.0 View Tag]] | [[trac:milestone:1.0 View Milestone]] == 0.12.x Releases === 0.12.7 //(May 20, 2015)// Trac 0.12.7 fixes a minor security issue, as well as a half dozen other minor issues: - InterWiki filters links through [wiki] safe_schemes option if [wiki] render_unsafe_content is disabled ([trac:#12053]). See the detailed release notes for [[trac:wiki:TracDev/ReleaseNotes/0.12#MaintenanceReleases | 0.12.7]]. [trac:source:/tags/trac-0.12.7 View Tag] | [trac:milestone:0.12.7 View Milestone] === 0.12.6 //(October 23, 2014)// Trac 0.12.6 contains fixes for a few issues: - Subversion blame would fail for a path with URL-encoded characters ([trac:#10386]), a lower-case drive letter on Windows ([trac:#10514]), or a non-ascii filename with Subversion 1.7 ([trac:#11167]). - Improved performance rendering svn:mergeinfo properties in browser view ([trac:#8459]) and changeset view ([trac:#11219]). - Query with many custom fields would fail ([trac:#11140]). - Zip archive had a timestamp with no timezone information ([trac:#11162]). - Failure or incorrect ranges rendering log TracLinks ([trac:#11308], [trac:#11346]). - Textareas in ticket view did not wrap correctly in IE 11 ([trac:#11376]). - Emails were not being obfuscated in owner field on CSV export from ticket and query pages ([trac:#11594]). - Locale data was not being included in egg in Distribute 0.6.29 and later ([trac:#11640]). - Deleting a milestone would not delete its attachments ([trac:#11672]). - Added support for Babel 1.0 and later ([trac:#11258], [trac:#11345]). - Added support for ConfigObj 5.0 and later ([trac:#11498]). - … and dozens more fixes! See the detailed release notes for [[trac:wiki:TracDev/ReleaseNotes/0.12#MaintenanceReleases | 0.12.6]]. [trac:source:/tags/trac-0.12.6 View Tag] | [trac:milestone:0.12.6 View Milestone] === 0.12.5 //(January 15, 2013)// Trac 0.12.5 contains fixes for a few issues: - upload of .mht files ([Wikipedia:MHTML] web page archive files) now works ([trac:#9880]) - more robust parsing of attachment URLs ([trac:#10280]) and uploaded file names ([trac:#10850]) - lots of improvement to the date formatting code, which is now much more robust when timezone and daylight saving time computations are involved ([trac:#10768], [trac:#10863], [trac:#10864], [trac:#10912], [trac:#10920]) - no longer generate invalid JSON encoded data with Python 2.4 and 2.5 ([trac:#10877]) - ... and fix a couple more minor defects ([trac:#10967], [trac:#10892], [trac:#10923], [trac:#10858], [trac:#10835]) [trac:source:/tags/trac-0.12.5 View Tag] | [trac:milestone:0.12.5 View Milestone] === 0.12.4 //(September 7, 2012)// Trac 0.12.4 contains only a handful of minor fixes. [trac:source:/tags/trac-0.12.4 View Tag] | [trac:milestone:0.12.4 View Milestone] === 0.12.3 === //(February 6, 2012)// Trac 0.12.3 contains a few minor fixes and a few minor features. - compatibility with Subversion 1.7 ([trac:#10414]) - easier troubleshooting of common startup errors ([trac:#10024]) - jQuery upgraded to 1.4.4 ([trac:#10001]) - improve fine-grained permission handling in the source browser ([trac:#9976], [trac:#10208], [trac:#10110]) - added compatibility with MySQL 5.5.3 utf8mb4 databases ([trac:#9766]) - ... and dozens more fixes! [trac:source:/tags/trac-0.12.3 View Tag] | [trac:milestone:0.12.3 View Milestone] === 0.12.2 //(January 31, 2011)// Trac 0.12.2 contains a few minor fixes and a few minor features. This list contains only a few highlights: - install: improved robustness of Trac installation if Babel is installed after the fact ([trac:#9439], [trac:#9595], [trac:#9961]) - notifications: support for Asian character width ([trac:#4717]) - roadmap: fix display of progress bar in some corner cases ([trac:#9718]) and respect the overall_completion milestone group setting ([trac:#9721]) - reports: reports and queries look much better, as the columns now keep the same width across groups; the absence of word wrapping in reports has been fixed ([trac:#9825]) - web admin: improved layout ([trac:#8866], [trac:#9963]) - web: it's now possible to log in different Trac instances sharing the same URL prefix (e.g. /project and /project-test) ([trac:#9951]) [trac:source:/tags/trac-0.12.2 View Tag] | [trac:milestone:0.12.2 View Milestone] === 0.12.1 //(October 9, 2010)// Trac 0.12.1 contains a few important performance improvements, some minor fixes and a few minor features. This list contains only a few highlights: - db: improve concurrency behavior ([trac:#9111]) - fcgi: add an environment variable TRAC_USE_FLUP to control the usage of flup vs. bundled _fcgi.py (defaults to 0, i.e. use bundled as before) - svn authz: improve compatibility with svn 1.5 format ([trac:#8289]) - milestone: allow to set the time for the due date ([trac:#6369], [trac:#9582]) - ticket: fixes for the CC: property ([trac:#8597], [trac:#9522]) - notification: improved the formatting of ticket fields in notification e-mails ([trac:#9484], [trac:#9494]) - i18n: added a configuration option to set the default language ([trac:#8117]) - several fixes for upgrade ([trac:#9400], [trac:#9416], [trac:#9483], [trac:#9556]) [trac:source:/tags/trac-0.12.1 View Tag] | [trac:milestone:0.12.1 View Milestone] === ''' 0.12 'Babel' ''' //(June 13, 2010)// Trac 0.12 is a major release introducing i18n and multiple repository support as the most visible changes. The following list contains only a few highlights: - The user interface is translated in a dozen of languages, provided the [Babel:] package is installed - Multiple repositories can be associated to a single Trac environment; the repositories can be of heterogeneous types (svn, hg, git, darcs...) - Usability improvements for the Wiki, with a nice side-by-side edit mode with automatic preview - Richer Wiki syntax, with much improved support for tables, partial [trac:WikiCreole] compatibility and numerous smaller improvements - Usability improvements for the Ticket module, with automatic preview of comments while you type and possibility to edit or remove them later - Improved Custom Queries (time fields, multiple disjoint conditions, a.k.a. OR queries) - Timeline filtering by user - ... and numerous smaller features added and bugs fixed since 0.11! [trac:source:/tags/trac-0.12 View Tag] | [trac:milestone:0.12 View Milestone] == Older Releases For releases prior to 0.12, see [trac:TracChangeLog@95].

• ## wiki/pages/TracIni

 r37567 = The Trac Configuration File [[TracGuideToc]] [[PageOutline]] Trac is configured by editing the **trac.ini** file, located in the /conf directory. The trac.ini configuration file and its parent directory should be writable by the web server. Trac monitors the timestamp of the file to trigger a complete environment reload and flush its caches when the timestamp changes. Most changes to the configuration will be reflected immediately, though changes to the [components] or [logging] sections will require restarting the web server. You may also need to restart the web server after creating a [#GlobalConfiguration global configuration] file when none was previously present. == Global Configuration Configuration can be shared among environments using one or more global configuration files. Options in the global configuration will be merged with the environment-specific options, with local options overriding global options. The global configuration file is specified as follows: {{{#!ini [inherit] file = /path/to/global/trac.ini }}} Multiple files can be specified using a comma-separated list. Note that you can also specify a global option file when creating a new project,  by adding the option --inherit=/path/to/global/trac.ini to [TracAdmin#initenv trac-admin]'s initenv command.  If you do not do this but nevertheless intend to use a global option file with your new environment, you will have to go through the newly generated conf/trac.ini file and delete the entries that will otherwise override those set in the global file. There are two more entries in the [[#inherit-section| [inherit] ]] section, templates_dir for sharing global templates and plugins_dir, for sharing plugins. Those entries can themselves be specified in the shared configuration file, and in fact, configuration files can even be chained if you specify another [inherit] file there. Note that the templates found in the templates/ directory of the TracEnvironment have precedence over those found in [inherit] templates_dir. In turn, the latter have precedence over the installed templates, so be careful about what you put there. Notably, if you override a default template, refresh your modifications when you upgrade to a new version of Trac. The preferred way to perform TracInterfaceCustomization is still to write a custom plugin doing an appropriate ITemplateStreamFilter transformation. == Reference for settings This is a brief reference of available configuration options, and their default settings. Documentation improvements should be discussed on the [trac:MailingList#Trac-dev trac-dev mailing list] or described in a [trac:NewTicket ticket]. Even better, [trac:TracDev/SubmittingPatches submit a patch] against the docstrings in the code. {{{ #!comment Please don't waste your time by editing the HTML code below, changes won't be picked up. Instead, follow the above guidance for suggesting documentation improvements. }}} [[TracIni]] ---- See also: TracGuide, TracAdmin, TracEnvironment
• ## wiki/pages/TracInstall

 r37567 = Trac Installation Guide for 1.1 [[TracGuideToc]] Trac is written in the Python programming language and needs a database, [http://sqlite.org/ SQLite], [http://www.postgresql.org/ PostgreSQL], or [http://mysql.com/ MySQL]. For HTML rendering, Trac uses the [http://genshi.edgewall.org Genshi] templating system. Trac can also be localized, and there is probably a translation available in your language. If you want to use the Trac interface in other languages, then make sure you have installed the optional package [#OtherPythonPackages Babel]. Pay attention to the extra steps for localization support in the [#InstallingTrac Installing Trac] section below. Lacking Babel, you will only get the default English version. If you're interested in contributing new translations for other languages or enhancing the existing translations, then please have a look at [trac:wiki:TracL10N TracL10N]. What follows are generic instructions for installing and setting up Trac. While you may find instructions for installing Trac on specific systems at [trac:TracInstallPlatforms TracInstallPlatforms], please '''first read through these general instructions''' to get a good understanding of the tasks involved. [[PageOutline(2-3,Installation Steps,inline)]] == Dependencies === Mandatory Dependencies To install Trac, the following software packages must be installed: * [http://www.python.org/ Python], version >= 2.6 and < 3.0 (note that we dropped the support for Python 2.5 in this release) * [http://pypi.python.org/pypi/setuptools setuptools], version >= 0.6 * [http://genshi.edgewall.org/wiki/Download Genshi], version >= 0.6 You also need a database system and the corresponding python bindings. The database can be either SQLite, PostgreSQL or MySQL. ==== For the SQLite database #ForSQLite As you must be using Python 2.6 or 2.7, you already have the SQLite database bindings bundled with the standard distribution of Python (the sqlite3 module). Optionally, you may install a newer version of [pypi:pysqlite pysqlite] than the one provided by the Python distribution. See [trac:PySqlite#ThePysqlite2bindings PySqlite] for details. ==== For the PostgreSQL database #ForPostgreSQL You need to install the database and its Python bindings: * [http://www.postgresql.org/ PostgreSQL], version 8.0 or later * [http://pypi.python.org/pypi/psycopg2 psycopg2], version 2.0 or later See [trac:DatabaseBackend#Postgresql DatabaseBackend] for details. ==== For the MySQL database #ForMySQL Trac works well with MySQL, provided you follow the guidelines: * [http://mysql.com/ MySQL], version 5.0 or later * [http://sf.net/projects/mysql-python MySQLdb], version 1.2.2 or later Given the caveats and known issues surrounding MySQL, read carefully the [trac:MySqlDb] page before creating the database. === Optional Dependencies ==== Subversion [http://subversion.apache.org/ Subversion], 1.6.x or later and the '''''corresponding''''' Python bindings. There are [http://subversion.apache.org/packages.html pre-compiled SWIG bindings] available for various platforms. (Good luck finding precompiled SWIG bindings for any Windows package at that listing. [trac:TracSubversion] points you to [http://alagazam.net Alagazam], which works for me under Python 2.6.) For troubleshooting information, see the [trac:TracSubversion#Troubleshooting TracSubversion] page. {{{#!div style="border: 1pt dotted; margin: 1em" **Note:** * Trac '''doesn't''' use [http://pysvn.tigris.org/ PySVN], nor does it work yet with the newer ctype-style bindings. * If using Subversion, Trac must be installed on the '''same machine'''. Remote repositories are currently [trac:ticket:493 not supported]. }}} ==== Git [http://git-scm.com/ Git] 1.5.6 or later is supported. More information is available on the [trac:TracGit] page. ==== Other Version Control Systems Support for other version control systems is provided via third-party plugins. See [trac:PluginList#VersionControlSystems] and [trac:VersionControlSystem]. ==== Web Server A web server is optional because Trac is shipped with a server included, see the [#RunningtheStandaloneServer Running the Standalone Server] section below. Alternatively you can configure Trac to run in any of the following environments: * [http://httpd.apache.org/ Apache] with - [https://github.com/GrahamDumpleton/mod_wsgi mod_wsgi], see [wiki:TracModWSGI] and [http://code.google.com/p/modwsgi/wiki/IntegrationWithTrac ModWSGI IntegrationWithTrac]. - [http://modpython.org/ mod_python 3.5.0], see TracModPython * a [http://www.fastcgi.com/ FastCGI]-capable web server (see TracFastCgi) * an [http://tomcat.apache.org/connectors-doc/ajp/ajpv13a.html AJP]-capable web server (see [trac:TracOnWindowsIisAjp TracOnWindowsIisAjp]) * Microsoft IIS with FastCGI and a FastCGI-to-WSGI gateway (see [trac:CookBook/Installation/TracOnWindowsIisWfastcgi IIS with FastCGI]) * a CGI-capable web server (see TracCgi), '''but usage of Trac as a cgi script is highly discouraged''', better use one of the previous options. ==== Other Python Packages * [http://babel.edgewall.org Babel], version 0.9.6 or >= 1.3, needed for localization support * [http://docutils.sourceforge.net/ docutils], version >= 0.3.9 for WikiRestructuredText. * [http://pygments.org Pygments] for [TracSyntaxColoring syntax highlighting]. * [http://pytz.sf.net pytz] to get a complete list of time zones, otherwise Trac will fall back on a shorter list from an internal time zone implementation. {{{#!div style="border: 1pt dotted; margin: 1em" **Attention**: The available versions of these dependencies are not necessarily interchangeable, so please pay attention to the version numbers. If you are having trouble getting Trac to work, please double-check all the dependencies before asking for help on the [trac:MailingList] or [trac:IrcChannel]. }}} Please refer to the documentation of these packages to find out how they are best installed. In addition, most of the [trac:TracInstallPlatforms platform-specific instructions] also describe the installation of the dependencies. Keep in mind however that the information there ''probably concern older versions of Trac than the one you're installing''. == Installing Trac The [TracAdmin trac-admin] command-line tool, used to create and maintain [TracEnvironment project environments], as well as the [TracStandalone tracd] standalone server are installed along with Trac. There are several methods for installing Trac. === Using easy_install Trac can be installed from PyPI or the Subversion repository using [http://pypi.python.org/pypi/setuptools setuptools]. A few examples: - Install Trac 1.0: {{{#!sh easy_install Trac==1.0 }}} - Install latest development version: {{{#!sh easy_install Trac==dev }}} Note that in this case you won't have the possibility to run a localized version of Trac; either use a released version or install from source More information can be found on the [trac:setuptools] page. {{{#!div style="border: 1pt dotted; margin: 1em" **Setuptools Warning:** If the version of your setuptools is in the range 5.4 through 5.6, the environment variable PKG_RESOURCES_CACHE_ZIP_MANIFESTS must be set in order to avoid significant performance degradation. More information may be found in the sections on [#RunningtheStandaloneServer Running The Standalone Server] and [#RunningTraconaWebServer Running Trac on a Web Server]. }}} === Using pip 'pip' is an easy_install replacement that is very useful to quickly install python packages. To get a Trac installation up and running in less than 5 minutes: Assuming you want to have your entire pip installation in /opt/user/trac - {{{#!sh pip install trac psycopg2 }}} or - {{{#!sh pip install trac mysql-python }}} Make sure your OS specific headers are available for pip to automatically build PostgreSQL (libpq-dev) or MySQL (libmysqlclient-dev) bindings. pip will automatically resolve all dependencies (like Genshi, pygments, etc.), download the latest packages from pypi.python.org and create a self contained installation in /opt/user/trac. All commands (tracd, trac-admin) are available in /opt/user/trac/bin. This can also be leveraged for mod_python (using PythonHandler directive) and mod_wsgi (using WSGIDaemonProcess directive) Additionally, you can install several Trac plugins (listed [https://pypi.python.org/pypi?:action=browse&show=all&c=516 here]) through pip. === From source Using the python-typical setup at the top of the source directory also works. You can obtain the source for a .tar.gz or .zip file corresponding to a release (e.g. Trac-1.0.tar.gz) from the [trac:TracDownload] page, or you can get the source directly from the repository. See [trac:TracRepositories#OfficialSubversionrepository TracRepositories] for details. {{{#!sh $python ./setup.py install }}} ''You will need root permissions or equivalent for this step.'' This will byte-compile the Python source code and install it as an .egg file or folder in the site-packages directory of your Python installation. The .egg will also contain all other resources needed by standard Trac, such as htdocs and templates. If you install from source and want to make Trac available in other languages, make sure Babel is installed. Only then, perform the install (or simply redo the install once again afterwards if you realize Babel was not yet installed): {{{#!sh$ python ./setup.py install }}} Alternatively, you can run bdist_egg and copy the .egg from dist/ to the place of your choice, or you can create a Windows installer (bdist_wininst). === Using installer On Windows, Trac can be installed using the exe installers available on the [trac:TracDownload] page. Installers are available for the 32-bit and 64-bit versions of Python. Make sure to use the installer that matches the architecture of your Python installation. === Using package manager Trac may be available in your platform's package repository. Note however, that the version provided by your package manager may not be the latest release. === Advanced easy_install Options To install Trac to a custom location, or find out about other advanced installation options, run: {{{#!sh easy_install --help }}} Also see [http://docs.python.org/2/install/index.html Installing Python Modules] for detailed information. Specifically, you might be interested in: {{{#!sh easy_install --prefix=/path/to/installdir }}} or, if installing Trac on a Mac OS X system: {{{#!sh easy_install --prefix=/usr/local --install-dir=/Library/Python/2.6/site-packages }}} {{{#!div style="border: 1pt dotted; margin: 1em" **Mac OS X Note:** On Mac OS X 10.6,  running easy_install trac will install into /usr/local and /Library/Python/2.6/site-packages by default. The tracd and trac-admin commands will be placed in /usr/local/bin and will install the Trac libraries and dependencies into /Library/Python/2.6/site-packages, which is Apple's preferred location for third-party Python application installations. }}} == Creating a Project Environment A [TracEnvironment Trac environment] is the backend where Trac stores information like wiki pages, tickets, reports, settings, etc. An environment is a directory that contains a human-readable [TracIni configuration file], and other files and directories. A new environment is created using [TracAdmin trac-admin]: {{{#!sh $trac-admin /path/to/myproject initenv }}} [TracAdmin trac-admin] will prompt you for the information it needs to create the environment: the name of the project and the [TracEnvironment#DatabaseConnectionStrings database connection string]. If you're not sure what to specify for any of these options, just press  to use the default value. Using the default database connection string will always work as long as you have SQLite installed. For the other [trac:DatabaseBackend database backends] you should plan ahead and already have a database ready to use at this point. Also note that the values you specify here can be changed later using TracAdmin or directly editing the [TracIni conf/trac.ini] configuration file. {{{#!div style="border: 1pt dotted; margin: 1em" **Filesystem Warning:** When selecting the location of your environment, make sure that the filesystem on which the environment directory resides supports sub-second timestamps (i.e. **not** ext2 or ext3 on Linux, or HFS+ on OSX), as the modification time of the conf/trac.ini file will be monitored to decide whether an environment restart is needed or not. A too coarse-grained timestamp resolution may result in inconsistencies in Trac < 1.0.2. The best advice is to opt for a platform with sub-second timestamp resolution, regardless of the Trac version. }}} Finally, make sure the user account under which the web front-end runs will have '''write permissions''' to the environment directory and all the files inside. This will be the case if you run trac-admin ... initenv as this user. If not, you should set the correct user afterwards. For example on Linux, with the web server running as user apache and group apache, enter: {{{#!sh$ chown -R apache:apache /path/to/myproject }}} The actual username and groupname of the apache server may not be exactly apache, and are specified in the Apache configuration file by the directives User and Group (if Apache httpd is what you use). {{{#!div class=important '''Warning:''' Please only use ASCII-characters for account name and project path, unicode characters are not supported there. }}} == Deploying Trac === Running the Standalone Server After having created a Trac environment, you can easily try the web interface by running the standalone server [TracStandalone tracd]: {{{#!sh $tracd --port 8000 /path/to/myproject }}} Then, fire up a browser and visit http://localhost:8000/. You should get a simple listing of all environments that tracd knows about. Follow the link to the environment you just created, and you should see Trac in action. If you only plan on managing a single project with Trac you can have the standalone server skip the environment list by starting it like this: {{{#!sh$ tracd -s --port 8000 /path/to/myproject }}} {{{#!div style="border: 1pt dotted; margin: 1em" **Setuptools Warning:** If the version of your setuptools is in the range 5.4 through 5.6, the environment variable PKG_RESOURCES_CACHE_ZIP_MANIFESTS must be set in order to avoid significant performance degradation. The environment variable can be set system-wide, or for just the user that runs the tracd process. There are several ways to accomplish this in addition to what is discussed here, and depending on the distribution of your OS. To be effective system-wide a shell script with the export statement may be added to /etc/profile.d. To be effective for a user session the export statement may be added to ~/.profile. {{{#!sh export PKG_RESOURCES_CACHE_ZIP_MANIFESTS=1 }}} Alternatively, the variable can be set in the shell before executing tracd: {{{#!sh $PKG_RESOURCES_CACHE_ZIP_MANIFESTS=1 tracd --port 8000 /path/to/myproject }}} }}} === Running Trac on a Web Server Trac provides various options for connecting to a "real" web server: - [TracFastCgi FastCGI] - [wiki:TracModWSGI mod_wsgi] - [TracModPython mod_python] - //[TracCgi CGI] (should not be used, as the performance is far from optimal)// Trac also supports [trac:TracOnWindowsIisAjp AJP] which may be your choice if you want to connect to IIS. Other deployment scenarios are possible: [trac:TracNginxRecipe nginx], [http://projects.unbit.it/uwsgi/wiki/Example#Traconapacheinasub-uri uwsgi], [trac:TracOnWindowsIisIsapi Isapi-wsgi] etc. ==== Generating the Trac cgi-bin directory #cgi-bin In order for Trac to function properly with FastCGI you need to have a trac.fcgi file and for mod_wsgi a trac.wsgi file. These are Python scripts which load the appropriate Python code. They can be generated using the deploy option of [TracAdmin trac-admin]. There is, however, a bit of a chicken-and-egg problem. The [TracAdmin trac-admin] command requires an existing environment to function, but complains if the deploy directory already exists. This is a problem, because environments are often stored in a subdirectory of the deploy. The solution is to do something like this: {{{#!sh mkdir -p /usr/share/trac/projects/my-project trac-admin /usr/share/trac/projects/my-project initenv trac-admin /usr/share/trac/projects/my-project deploy /tmp/deploy mv /tmp/deploy/* /usr/share/trac }}} Don't forget to check that the web server has the execution right on scripts in the /usr/share/trac/cgi-bin directory. ==== Mapping Static Resources Out of the box, Trac will pass static resources such as style sheets or images through itself. For anything but a tracd only based deployment, this is far from optimal as the web server could be set up to directly serve those static resources (for CGI setup, this is '''highly undesirable''' and will cause abysmal performance). Web servers such as [http://httpd.apache.org/ Apache] allow you to create “Aliases” to resources, giving them a virtual URL that doesn't necessarily reflect the layout of the servers file system. We also can map requests for static resources directly to the directory on the file system, avoiding processing these requests by Trac itself. There are two primary URL paths for static resources - /chrome/common and /chrome/site. Plugins can add their own resources, usually accessible by /chrome/ path, so its important to override only known paths and not try to make universal /chrome alias for everything. Note that in order to get those static resources on the filesystem, you need first to extract the relevant resources from Trac using the TracAdmin deploy command: [[TracAdminHelp(deploy)]] The target  will then contain an htdocs directory with: - site/ - a copy of the environment's directory htdocs/ - common/ - the static resources of Trac itself - / - one directory for each resource directory managed by the plugins enabled for this environment ===== Example: Apache and ScriptAlias #ScriptAlias-example Assuming the deployment has been done this way: {{{#!sh$ trac-admin /var/trac/env deploy /path/to/shared/trac }}} Add the following snippet to Apache configuration ''before'' the ScriptAlias or WSGIScriptAlias (which map all the other requests to the Trac application), changing paths to match your deployment: {{{#!apache Alias /trac/chrome/common /path/to/trac/htdocs/common Alias /trac/chrome/site /path/to/trac/htdocs/site Order allow,deny Allow from all }}} If using mod_python, you might want to add this too (otherwise, the alias will be ignored): {{{#!apache SetHandler None }}} Note that we mapped the /trac part of the URL to the trac.*cgi script, and the path /trac/chrome/common is the path you have to append to that location to intercept requests to the static resources. Similarly, if you have static resources in a project's htdocs directory (which is referenced by /trac/chrome/site URL in themes), you can configure Apache to serve those resources (again, put this ''before'' the ScriptAlias or WSGIScriptAlias for the .*cgi scripts, and adjust names and locations to match your installation): {{{#!apache Alias /trac/chrome/site /path/to/projectenv/htdocs Order allow,deny Allow from all }}} Alternatively to aliasing /trac/chrome/common, you can tell Trac to generate direct links for those static resources (and only those), using the [[TracIni#trac-section| [trac] htdocs_location]] configuration setting: {{{#!ini [trac] htdocs_location = http://static.example.org/trac-common/ }}} Note that this makes it easy to have a dedicated domain serve those static resources (preferentially [http://code.google.com/speed/page-speed/docs/request.html#ServeFromCookielessDomain cookie-less]). Of course, you still need to make the Trac htdocs/common directory available through the web server at the specified URL, for example by copying (or linking) the directory into the document root of the web server: {{{#!sh $ln -s /path/to/trac/htdocs/common /var/www/static.example.org/trac-common }}} ==== Setting up the Plugin Cache Some Python plugins need to be extracted to a cache directory. By default the cache resides in the home directory of the current user. When running Trac on a Web Server as a dedicated user (which is highly recommended) who has no home directory, this might prevent the plugins from starting. To override the cache location you can set the PYTHON_EGG_CACHE environment variable. Refer to your server documentation for detailed instructions on how to set environment variables. == Configuring Authentication Trac uses HTTP authentication. You'll need to configure your webserver to request authentication when the .../login URL is hit (the virtual path of the "login" button). Trac will automatically pick the REMOTE_USER variable up after you provide your credentials. Therefore, all user management goes through your web server configuration. Please consult the documentation of your web server for more info. The process of adding, removing, and configuring user accounts for authentication depends on the specific way you run Trac. Please refer to one of the following sections: * TracStandalone#UsingAuthentication if you use the standalone server, tracd. * [wiki:TracModWSGI#ConfiguringAuthentication TracModWSGI#ConfiguringAuthentication] if you use the Apache web server, with any of its front end: mod_wsgi, mod_python, mod_fcgi or mod_fastcgi. * TracFastCgi if you're using another web server with FCGI support (Cherokee, Lighttpd, !LiteSpeed, nginx) [trac:TracAuthenticationIntroduction] also contains some useful information for beginners. == Granting admin rights to the admin user Grant admin rights to user admin: {{{#!sh$ trac-admin /path/to/myproject permission add admin TRAC_ADMIN }}} This user will have an //Admin// navigation item that directs to pages for administering your Trac project. == Configuring Trac TracRepositoryAdmin provides information on configuring version control repositories for your project. == Using Trac Once you have your Trac site up and running, you should be able to create tickets, view the timeline, browse your version control repository if configured, etc. Keep in mind that //anonymous// (not logged in) users can by default access only a few of the features, in particular they will have a read-only access to the resources. You will need to configure authentication and grant additional [TracPermissions permissions] to authenticated users to see the full set of features. '' Enjoy! '' [trac:TracTeam The Trac Team] ---- See also: [trac:TracInstallPlatforms TracInstallPlatforms], TracGuide, TracUpgrade, TracPermissions
• ## wiki/pages/TracInterfaceCustomization

 r37662 = Customizing the Trac Interface [[TracGuideToc]] [[PageOutline]] == Introduction This page gives suggestions on how to customize the look of Trac. Topics include editing the HTML templates and CSS files, but not the program code itself. The topics show users how they can modify the look of Trac to meet their specific needs. Suggestions for changes to Trac's interface applicable to all users should be filed as tickets, not listed on this page. == Project Logo and Icon The easiest parts of the Trac interface to customize are the logo and the site icon. Both of these can be configured with settings in [wiki:TracIni trac.ini]. The logo or icon image should be put in a folder named "htdocs" in your project's environment folder. ''Note: in projects created with a Trac version prior to 0.9 you will need to create this folder''. '''Note''': you can actually put the logo and icon anywhere on your server (as long as it's accessible through the web server), and use their absolute or server-relative URLs in the configuration. Now configure the appropriate section of your [wiki:TracIni trac.ini]: === Logo Change the src setting to site/ followed by the name of your image file. The width and height settings should be modified to match your image's dimensions. The Trac chrome handler uses "site/" for files within the project directory htdocs, and "common/" for the common htdocs directory belonging to a Trac installation. Note that 'site/' is not a placeholder for your project name, it is the literal prefix that should be used. For example, if your project is named 'sandbox', and the image file is 'red_logo.gif' then the 'src' setting would be 'site/red_logo.gif', not 'sandbox/red_logo.gif'. {{{#!ini [header_logo] src = site/my_logo.gif alt = My Project width = 300 height = 100 }}} === Icon Icons are small images displayed by your web browser next to the site's URL and in the Bookmarks menu. Icons should be a 32x32 image in .gif or .ico format. Change the icon setting to site/ followed by the name of your icon file: {{{#!ini [project] icon = site/my_icon.ico }}} == Custom Navigation Entries The new [mainnav] and [metanav] can now be used to customize the text and link used for the navigation items, or even to disable them, but not for adding new ones. In the following example, we rename the link to the Wiki start "Home", and hide the "!Help/Guide". We also make the "View Tickets" entry link to a specific report: {{{#!ini [mainnav] wiki.label = Home tickets.href = /report/24 [metanav] help = disabled }}} See also TracNavigation for a more detailed explanation of the mainnav and metanav terms. == Site Appearance == #SiteAppearance Trac is using [http://genshi.edgewall.org Genshi] as the templating engine. Say you want to add a link to a custom stylesheet, and then your own header and footer. Save the following content as site.html inside your projects templates/ directory (each Trac project can have their own site.html), eg /path/to/env/templates/site.html: {{{#!xml ${select('*|comment()|text()')}${select('*|text()')} }}} Notice that XSLT bears some similarities with Genshi templates. However, there are some Trac specific features, for example the ${href.chrome('site/style.css')} attribute references style.css in the environment's htdocs/ directory. In a similar fashion ${chrome.htdocs_location} is used to specify the common htdocs/ directory belonging to a Trac installation. That latter location can however be overriden using the [[TracIni#trac-section|[trac] htdocs_location]] configuration setting. site.html is one file to contain all your modifications. It usually works using the py:match directive (element or attribute), and it allows you to modify the page as it renders. The matches hook onto specific sections depending on what it tries to find and modify them. See [http://groups.google.com/group/trac-users/browse_thread/thread/70487fb2c406c937/ this thread] for a detailed explanation of the above example site.html. A site.html can contain any number of such py:match sections for whatever you need to modify. This is all Genshi, so the [http://genshi.edgewall.org/wiki/Documentation/xml-templates.html docs on the exact syntax] can be found there. Example snippet of adding introduction text to the new ticket form (but not shown during preview): {{{#!xml

Please make sure to search for existing tickets before reporting a new one!

• ## wiki/pages/TracModPython

 r37567 [[TracGuideToc]] = Trac and mod_python Mod_python is an [https://httpd.apache.org/ Apache] module that embeds the Python interpreter within the server, so that web-based applications in Python will run many times faster than traditional CGI and will have the ability to retain database connections. Trac supports [http://www.modpython.org/ mod_python], which speeds up Trac's response times considerably, especially compared to [TracCgi CGI], and permits use of many Apache features not possible with [wiki:TracStandalone tracd]/mod_proxy. These instructions are for Apache 2. If you are using Apache 1.3, you may have some luck with [trac:wiki:TracModPython2.7 TracModPython2.7], but that is a deprecated setup. [[PageOutline(2-3,Overview,inline)]] == Simple configuration: single project == #Simpleconfiguration If you just installed mod_python, you may have to add a line to load the module in the Apache configuration: {{{#!apache LoadModule python_module modules/mod_python.so }}} '''Note''': The exact path to the module depends on how the HTTPD installation is laid out. On Debian using apt-get: {{{#!sh apt-get install libapache2-mod-python libapache2-mod-python-doc }}} Still on Debian, after you have installed mod_python, you must enable the modules in apache2, equivalent to the above Load Module directive: {{{#!sh a2enmod python }}} On Fedora use, using yum: {{{#!sh yum install mod_python }}} You can test your mod_python installation by adding the following to your httpd.conf. You should remove this when you are done testing for security reasons. Note: mod_python.testhandler is only available in mod_python 3.2+. {{{#!apache SetHandler mod_python PythonInterpreter main_interpreter PythonHandler mod_python.testhandler Order allow,deny Allow from all }}} A simple setup of Trac on mod_python looks like this: {{{#!apache SetHandler mod_python PythonInterpreter main_interpreter PythonHandler trac.web.modpython_frontend PythonOption TracEnv /var/trac/myproject PythonOption TracUriRoot /projects/myproject Order allow,deny Allow from all }}} The option '''TracUriRoot''' may or may not be necessary in your setup. Try your configuration without it; if the URLs produced by Trac look wrong, if Trac does not seem to recognize URLs correctly, or you get an odd "No handler matched request to..." error, add the '''TracUriRoot''' option. You will notice that the Location and '''TracUriRoot''' have the same path. The options available are: {{{#!apache # For a single project PythonOption TracEnv /var/trac/myproject # For multiple projects PythonOption TracEnvParentDir /var/trac/myprojects # For the index of multiple projects PythonOption TracEnvIndexTemplate /srv/www/htdocs/trac/project_list_template.html # A space delimitted list, with a "," between key and value pairs. PythonOption TracTemplateVars key1,val1 key2,val2 # Useful to get the date in the wanted order PythonOption TracLocale en_GB.UTF8 # See description above PythonOption TracUriRoot /projects/myproject }}} === Python Egg Cache Compressed Python eggs like Genshi are normally extracted into a directory named .python-eggs in the users home directory. Since Apache's home usually is not writeable, an alternate egg cache directory can be specified like this: {{{#!apache PythonOption PYTHON_EGG_CACHE /var/trac/myprojects/egg-cache }}} Or you can uncompress the Genshi egg to resolve problems extracting from it. === Configuring Authentication See corresponding section in the [wiki:TracModWSGI#ConfiguringAuthentication] page. == Advanced Configuration === Setting the Python Egg Cache If the Egg Cache isn't writeable by your Web server, you'll either have to change the permissions, or point Python to a location where Apache can write. This can manifest itself as a 500 internal server error and/or a complaint in the syslog. {{{#!apache ... PythonOption PYTHON_EGG_CACHE /tmp ... }}} === Setting the !PythonPath If the Trac installation isn't installed in your Python path, you will have to tell Apache where to find the Trac mod_python handler  using the PythonPath directive: {{{#!apache ... PythonPath "sys.path + ['/path/to/trac']" ... }}} Be careful about using the !PythonPath directive, and ''not'' SetEnv PYTHONPATH, as the latter won't work. === Setting up multiple projects The Trac mod_python handler supports a configuration option similar to Subversion's SvnParentPath, called TracEnvParentDir: {{{#!apache SetHandler mod_python PythonInterpreter main_interpreter PythonHandler trac.web.modpython_frontend PythonOption TracEnvParentDir /var/trac PythonOption TracUriRoot /projects }}} When you request the /projects URL, you will get a listing of all subdirectories of the directory you set as TracEnvParentDir that look like Trac environment directories. Selecting any project in the list will bring you to the corresponding Trac environment. If you don't want to have the subdirectory listing as your projects home page you can use a {{{#!apache }}} This will instruct Apache to use mod_python for all locations different from root while having the possibility of placing a custom home page for root in your !DocumentRoot folder. You can also use the same authentication realm for all of the projects using a  directive: {{{#!apache AuthType Basic AuthName "Trac" AuthUserFile /var/trac/.htpasswd Require valid-user }}} === Virtual Host Configuration Below is the sample configuration required to set up your Trac as a virtual server, ie when you access it at the URLs like http://trac.mycompany.com: {{{#!apache DocumentRoot /var/www/myproject ServerName trac.mycompany.com SetHandler mod_python PythonInterpreter main_interpreter PythonHandler trac.web.modpython_frontend PythonOption TracEnv /var/trac/myproject PythonOption TracUriRoot / AuthType Basic AuthName "MyCompany Trac Server" AuthUserFile /var/trac/myproject/.htpasswd Require valid-user }}} This does not seem to work in all cases. What you can do if it does not: * Try using  instead of . *  may, in your server setup, refer to the complete host instead of simple the root of the server. This means that everything (including the login directory referenced below) will be sent to Python and authentication does not work, ie you get the infamous Authentication information missing error. If this is the case, try using a sub-directory for Trac instead of the root, ie /web/ and /web/login instead of / and /login. * Depending on apache's NameVirtualHost configuration, you may need to use  instead of . For a virtual host that supports multiple projects replace TracEnv /var/trac/myproject with TracEnvParentDir /var/trac. '''Note''': !DocumentRoot should not point to your Trac project env. As Asmodai wrote on #trac: "suppose there's a webserver bug that allows disclosure of !DocumentRoot they could then leech the entire Trac environment". == Troubleshooting If you get server error pages, you can either check the Apache error log, or enable the PythonDebug option: {{{#!apache ... PythonDebug on }}} For multiple projects, try restarting the server as well. === Login Not Working If you've used  directive, it will override any other directives, as well as . The workaround is to use negation expression as follows (for multi project setups): {{{#!apache #this one for other pages SetHandler mod_python PythonHandler trac.web.modpython_frontend PythonOption TracEnvParentDir /projects PythonOption TracUriRoot / #this one for login page SetHandler mod_python PythonHandler trac.web.modpython_frontend PythonOption TracEnvParentDir /projects PythonOption TracUriRoot / #remove these if you don't want to force SSL RewriteEngine On RewriteCond %{HTTPS} off RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} AuthType Basic AuthName "Trac" AuthUserFile /projects/.htpasswd Require valid-user }}} === Expat-related segmentation faults === #expat This problem will most certainly hit you on Unix when using Python 2.4. In Python 2.4, some version of [http://expat.sourceforge.net/ Expat] (an XML parser library written in C) is used and if Apache is using another version, this results in segmentation faults. As Trac 0.11 is using Genshi, which will indirectly use Expat, that problem can now hit you even if everything was working fine before with Trac 0.10. This problem has not been reported for Python 2.5+, so best to upgrade. === Form submission problems If you're experiencing problems submitting some of the forms in Trac (a common problem is that you get redirected to the start page after submission), check whether your {{{DocumentRoot}}} contains a folder or file with the same path that you mapped the mod_python handler to. For some reason, mod_python gets confused when it is mapped to a location that also matches a static resource. === Problem with virtual host configuration If the directive is used, setting the DocumentRoot may result in a ''403 (Forbidden)'' error. Either remove the DocumentRoot directive, or make sure that accessing the directory it points is allowed, in a corresponding  block. Using together with SetHandler resulted in having everything handled by mod_python, which leads to not being able to download any CSS or images/icons. Use SetHandler None to circumvent the problem, though this may not be the most elegant solution. === Problem with zipped egg It's possible that your version of mod_python will not import modules from zipped eggs. If you encounter an ImportError: No module named trac in your Apache logs but you think everything is where it should be, this might be your problem. Look in your site-packages directory; if the Trac module appears as a ''file'' rather than a ''directory'', then this might be your problem. To rectify this, try installing Trac using the --always-unzip option: {{{#!sh easy_install --always-unzip Trac-0.12b1.zip }}} === Using .htaccess Although it may seem trivial to rewrite the above configuration as a directory in your document root with a .htaccess file, this does not work. Apache will append a "/" to any Trac URLs, which interferes with its correct operation. It may be possible to work around this with mod_rewrite, but I failed to get this working. In all, it is more hassle than it is worth. This also works out-of-box, with following trivial config: {{{#!apache SetHandler mod_python PythonInterpreter main_interpreter PythonHandler trac.web.modpython_frontend PythonOption TracEnv /system/path/to/this/directory PythonOption TracUriRoot /path/on/apache AuthType Basic AuthName "ProjectName" AuthUserFile /path/to/.htpasswd Require valid-user }}} The TracUriRoot is obviously the path you need to enter to the browser to get to Trac, eg domain.tld/projects/trac. === Additional .htaccess help If you are using the .htaccess method you may have additional problems if your Trac directory is inheriting .htaccess directives from another. This may also help to add to your .htaccess file: {{{#!apache RewriteEngine Off }}} === Platform specific issues ==== Win32 Issues If you run Trac with mod_python < 3.2 on Windows, uploading attachments will '''not''' work. This problem is resolved in mod_python 3.1.4 or later, so please upgrade mod_python to fix this. ==== OS X issues When using mod_python on OS X you will not be able to restart Apache using apachectl restart. This is apparently fixed in mod_python 3.2, so please upgrade mod_python to fix this. ==== SELinux issues If Trac reports something like: Cannot get shared lock on db.lock, then the security context on the repository may need to be set: {{{#!sh chcon -R -h -t httpd_sys_content_t PATH_TO_REPOSITORY }}} See also [http://subversion.apache.org/faq.html#reposperms How do I set repository permissions correctly?] ==== FreeBSD issues The FreeBSD ports have both the new and old versions of mod_python and SQLite, but earlier versions of pysqlite and mod_python won't integrate: * pysqlite requires threaded support in Python * mod_python requires a threadless install. Apache2 does not automatically support threads on FreeBSD. You could force thread support when running ./configure for Apache, using --enable-threads, but this isn´t recommended. The best option [http://modpython.org/pipermail/mod_python/2006-September/021983.html seems to be] adding to /usr/local/apache2/bin/ennvars the line: {{{#!sh export LD_PRELOAD=/usr/lib/libc_r.so }}} ==== Fedora 7 Issues Make sure you install the 'python-sqlite2' package as it seems to be required for TracModPython, but not for tracd. === Subversion issues If you get the following Trac error Unsupported version control system "svn" only under mod_python, though it works well on the command-line and even with TracStandalone, chances are that you forgot to add the path to the Python bindings with the [TracModPython#ConfiguringPythonPath PythonPath] directive. A better way is to add a link to the bindings in the Python site-packages directory, or create a .pth file in that directory. If this is not the case, it's possible that you are using Subversion libraries that are binary incompatible with the Apache ones and an incompatibility of the apr libraries is usually the cause. In that case, you also won't be able to use the svn modules for Apache (mod_dav_svn). You also need a recent version of mod_python in order to avoid a runtime error ({{{argument number 2: a 'apr_pool_t *' is expected}}}) due to the default usage of multiple sub-interpreters. Version 3.2.8 ''should'' work, though it's probably better to use the workaround described in [trac:#3371 #3371], in order to force the use of the main interpreter: {{{#!apache PythonInterpreter main_interpreter }}} This is also the recommended workaround for other issues seen when using the Python bindings for Subversion within mod_python ([trac:#2611 #2611], [trac:#3455 #3455]). See in particular Graham Dumpleton's comment in [trac:comment:9:ticket:3455 #3455] explaining the issue. === Page layout issues If the formatting of the Trac pages look weird, chances are that the style sheets governing the page layout are not handled properly by the web server. Try adding the following lines to your Apache configuration: {{{#!apache Alias /myproject/css "/usr/share/trac/htdocs/css" SetHandler None }}} '''Note''': For the above configuration to have any effect it must be put after the configuration of your project root location, ie {{{}}}. Also, setting PythonOptimize On seems to mess up the page headers and footers, in addition to hiding the documentation for macros and plugins (see #Trac8956). Considering how little effect the option has, leave it Off. === HTTPS issues If you want to run Trac fully under https you might find that it tries to redirect to plain http. In this case just add the following line to your Apache configuration: {{{#!apache DocumentRoot /var/www/myproject ServerName trac.mycompany.com SetEnv HTTPS 1 .... }}} === Segmentation fault with php5-mhash or other php5 modules You may encounter segfaults (reported on Debian etch) if php5-mhash module is installed. Try to remove it to see if this solves the problem. See [http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=411487 Debian bug report]. Some people also have troubles when using PHP5 compiled with its own third party libraries instead of system libraries. Check [http://www.djangoproject.com/documentation/modpython/#if-you-get-a-segmentation-fault Django segmentation fault]. ---- See also: TracGuide, TracInstall, [wiki:TracModWSGI ModWSGI], [wiki:TracFastCgi FastCGI], [trac:TracNginxRecipe]

 r37567 = Trac and mod_wsgi [https://github.com/GrahamDumpleton/mod_wsgi mod_wsgi] is an Apache module for running WSGI-compatible Python applications directly on top of the Apache webserver. The mod_wsgi adapter is written completely in C and provides very good performance. [[PageOutline(2-3,Overview,inline)]] == The trac.wsgi script Trac can be run on top of mod_wsgi with the help of an application script, which is just a Python file saved with a .wsgi extension. A robust and generic version of this file can be created using the trac-admin deploy  command which automatically substitutes the required paths, see TracInstall#cgi-bin. The script should be sufficient for most installations and users not wanting more information can proceed to [#Mappingrequeststothescript configuring Apache]. If you are using Trac with multiple projects, you can specify their common parent directory using the TRAC_ENV_PARENT_DIR in trac.wsgi: {{{#!python def application(environ, start_request): # Add this to config when you have multiple projects environ.setdefault('trac.env_parent_dir', '/usr/share/trac/projects') .. }}} === A very basic script In its simplest form, the script could be: {{{#!python import os os.environ['TRAC_ENV'] = '/usr/local/trac/mysite' os.environ['PYTHON_EGG_CACHE'] = '/usr/local/trac/mysite/eggs' import trac.web.main application = trac.web.main.dispatch_request }}} The TRAC_ENV variable should naturally be the directory for your Trac environment, and the PYTHON_EGG_CACHE should be a directory where Python can temporarily extract Python eggs. If you have several Trac environments in a directory, you can also use TRAC_ENV_PARENT_DIR instead of TRAC_ENV. On Windows: - If run under the user's session, the Python Egg cache can be found in %AppData%\Roaming, for example: {{{#!python os.environ['PYTHON_EGG_CACHE'] = r'C:\Users\Administrator\AppData\Roaming\Python-Eggs' }}} - If run under a Window service, you should create a directory for Python Egg cache: {{{#!python os.environ['PYTHON_EGG_CACHE'] = r'C:\Trac-Python-Eggs' }}} === A more elaborate script If you are using multiple .wsgi files (for example one per Trac environment) you must ''not'' use os.environ['TRAC_ENV'] to set the path to the Trac environment. Using this method may lead to Trac delivering the content of another Trac environment, as the variable may be filled with the path of a previously viewed Trac environment. To solve this problem, use the following .wsgi file instead: {{{#!python import os os.environ['PYTHON_EGG_CACHE'] = '/usr/local/trac/mysite/eggs' import trac.web.main def application(environ, start_response): environ['trac.env_path'] = '/usr/local/trac/mysite' return trac.web.main.dispatch_request(environ, start_response) }}} For clarity, you should give this file a .wsgi extension. You should probably put the file in its own directory, since you will expose it to Apache. If you have installed Trac and Python eggs in a path different from the standard one, you should add that path by adding the following code at the top of the wsgi script: {{{#!python import site site.addsitedir('/usr/local/trac/lib/python2.4/site-packages') }}} Change it according to the path you installed the Trac libs at. == Mapping requests to the script After preparing your .wsgi script, add the following to your Apache configuration file, typically httpd.conf: {{{#!apache WSGIScriptAlias /trac /usr/local/trac/mysite/apache/mysite.wsgi WSGIApplicationGroup %{GLOBAL} Order deny,allow Allow from all }}} Here, the script is in a subdirectory of the Trac environment. If you followed the directions [TracInstall#cgi-bin Generating the Trac cgi-bin directory], your Apache configuration file should look like following: {{{#!apache WSGIScriptAlias /trac /usr/share/trac/cgi-bin/trac.wsgi WSGIApplicationGroup %{GLOBAL} Order deny,allow Allow from all }}} In order to let Apache run the script, access to the directory in which the script resides is opened up to all of Apache. Additionally, the WSGIApplicationGroup directive ensures that Trac is always run in the first Python interpreter created by mod_wsgi. This is necessary because the Subversion Python bindings, which are used by Trac, don't always work in other sub-interpreters and may cause requests to hang or cause Apache to crash. After adding this configuration, restart Apache, and then it should work. To test the setup of Apache, mod_wsgi and Python itself (ie. without involving Trac and dependencies), this simple wsgi application can be used to make sure that requests gets served (use as only content in your .wsgi script): {{{#!python def application(environ, start_response): start_response('200 OK',[('Content-type','text/html')]) return ['Hello World!'] }}} For more information about using the mod_wsgi specific directives, see the [http://code.google.com/p/modwsgi/wiki/ mod_wsgi's wiki] and more specifically the [http://code.google.com/p/modwsgi/wiki/IntegrationWithTrac IntegrationWithTrac] page. == Configuring Authentication The following sections describe different methods for setting up authentication. See also [http://httpd.apache.org/docs/2.2/howto/auth.html Authentication, Authorization and Access Control] in the Apache guide. === Using Basic Authentication The simplest way to enable authentication with Apache is to create a password file. Use the htpasswd program as follows: {{{#!sh $htpasswd -c /somewhere/trac.htpasswd admin New password: Re-type new password: Adding password for user admin }}} After the first user, you don't need the "-c" option anymore: {{{#!sh$ htpasswd /somewhere/trac.htpasswd john New password: Re-type new password: Adding password for user john }}} ''See the man page for htpasswd for full documentation.'' After you've created the users, you can set their permissions using TracPermissions. Now, you need to enable authentication against the password file in the Apache configuration: {{{#!apache AuthType Basic AuthName "Trac" AuthUserFile /somewhere/trac.htpasswd Require valid-user }}} If you are hosting multiple projects, you can use the same password file for all of them: {{{#!apache AuthType Basic AuthName "Trac" AuthUserFile /somewhere/trac.htpasswd Require valid-user }}} Note that neither a file nor a directory named 'login' needs to exist.[[BR]] See also the [http://httpd.apache.org/docs/2.2/mod/mod_auth_basic.html mod_auth_basic] documentation. === Using Digest Authentication For better security, it is recommended that you either enable SSL or at least use the “digest” authentication scheme instead of “Basic”. You have to create your .htpasswd file with the htdigest command instead of htpasswd, as follows: {{{#!sh $htdigest -c /somewhere/trac.htpasswd trac admin }}} The "trac" parameter above is the "realm", and will have to be reused in the Apache configuration in the !AuthName directive: {{{#!apache AuthType Digest AuthName "trac" AuthDigestDomain /trac AuthUserFile /somewhere/trac.htpasswd Require valid-user }}} For multiple environments, you can use the same LocationMatch as described with the previous method. '''Note: Location cannot be used inside .htaccess files, but must instead live within the main httpd.conf file. If you are on a shared server, you therefore will not be able to provide this level of granularity. ''' Don't forget to activate the mod_auth_digest. For example, on a Debian 4.0r1 (etch) system: {{{#!apache LoadModule auth_digest_module /usr/lib/apache2/modules/mod_auth_digest.so }}} See also the [http://httpd.apache.org/docs/2.2/mod/mod_auth_digest.html mod_auth_digest] documentation. === Using LDAP Authentication Configuration for [http://httpd.apache.org/docs/2.2/mod/mod_ldap.html mod_ldap] authentication in Apache is more involved (httpd 2.2.x and OpenLDAP: slapd 2.3.19). 1. You need to load the following modules in Apache httpd.conf: {{{#!apache LoadModule ldap_module modules/mod_ldap.so LoadModule authnz_ldap_module modules/mod_authnz_ldap.so }}} 1. Your httpd.conf also needs to look something like: {{{#!apache # (if you're using it, mod_python specific settings go here) Order deny,allow Deny from all Allow from 192.168.11.0/24 AuthType Basic AuthName "Trac" AuthBasicProvider "ldap" AuthLDAPURL "ldap://127.0.0.1/dc=example,dc=co,dc=ke?uid?sub?(objectClass=inetOrgPerson)" authzldapauthoritative Off Require valid-user }}} 1. You can use the LDAP interface as a way to authenticate to a Microsoft Active Directory. Use the following as your LDAP URL: {{{#!apache AuthLDAPURL "ldap://directory.example.com:3268/DC=example,DC=com?sAMAccountName?sub?(objectClass=user)" }}} You will also need to provide an account for Apache to use when checking credentials. As this password will be listed in plaintext in the config, you need to use an account specifically for this task: {{{#!apache AuthLDAPBindDN ldap-auth-user@example.com AuthLDAPBindPassword "password" }}} The whole section looks like: {{{#!apache # (if you're using it, mod_python specific settings go here) Order deny,allow Deny from all Allow from 192.168.11.0/24 AuthType Basic AuthName "Trac" AuthBasicProvider "ldap" AuthLDAPURL "ldap://adserver.company.com:3268/DC=company,DC=com?sAMAccountName?sub?(objectClass=user)" AuthLDAPBindDN ldap-auth-user@company.com AuthLDAPBindPassword "the_password" authzldapauthoritative Off # require valid-user Require ldap-group CN=Trac Users,CN=Users,DC=company,DC=com }}} Note 1: This is the case where the LDAP search will get around the multiple OUs, conecting to the Global Catalog Server portion of AD. Note the port is 3268, not the normal LDAP 389. The GCS is basically a "flattened" tree which allows searching for a user without knowing to which OU they belong. Note 2: You can also require the user be a member of a certain LDAP group, instead of just having a valid login: {{{#!apache Require ldap-group CN=Trac Users,CN=Users,DC=example,DC=com }}} See also: - [http://httpd.apache.org/docs/2.2/mod/mod_authnz_ldap.html mod_authnz_ldap], documentation for mod_authnz_ldap. - [http://httpd.apache.org/docs/2.2/mod/mod_ldap.html mod_ldap], documentation for mod_ldap, which provides connection pooling and a shared cache. - [http://trac-hacks.org/wiki/LdapPlugin TracHacks:LdapPlugin] for storing TracPermissions in LDAP. === Using SSPI Authentication If you are using Apache on Windows, you can use mod_auth_sspi to provide single-sign-on. Download the module from the !SourceForge [http://sourceforge.net/projects/mod-auth-sspi/ mod-auth-sspi project] and then add the following to your !VirtualHost: {{{#!apache AuthType SSPI AuthName "Trac Login" SSPIAuth On SSPIAuthoritative On SSPIDomain MyLocalDomain SSPIOfferBasic On SSPIOmitDomain Off SSPIBasicPreferred On Require valid-user }}} Using the above, usernames in Trac will be of the form DOMAIN\username, so you may have to re-add permissions and such. If you do not want the domain to be part of the username, set SSPIOmitDomain On instead. Some common problems with SSPI authentication: [trac:#1055], [trac:#1168] and [trac:#3338]. See also [trac:TracOnWindows/Advanced]. === Using Apache authentication with the Account Manager plugin's Login form === To begin with, see the basic instructions for using the Account Manager plugin's [http://trac-hacks.org/wiki/AccountManagerPlugin/Modules#LoginModule Login module] and its [http://trac-hacks.org/wiki/AccountManagerPlugin/AuthStores#HttpAuthStore HttpAuthStore authentication module]. '''Note:''' If is difficult to get !HttpAuthStore to work with WSGI when using any Account Manager version prior to acct_mgr-0.4. Upgrading is recommended. Here is an example (from the !HttpAuthStore link) using acct_mgr-0.4 for hosting a single project: {{{#!ini [components] ; be sure to enable the component acct_mgr.http.HttpAuthStore = enabled [account-manager] ; configure the plugin to use a page that is secured with http authentication authentication_url = /authFile password_store = HttpAuthStore }}} This will generally be matched with an Apache config like: {{{#!apache …HTTP authentication configuration… Require valid-user }}} Note that '''authFile''' need not exist (unless you are using Account Manager older than 0.4). See the !HttpAuthStore link above for examples where multiple Trac projects are hosted on a server. === Example: Apache/mod_wsgi with Basic Authentication, Trac being at the root of a virtual host Per the mod_wsgi documentation linked to above, here is an example Apache configuration that: - serves the Trac instance from a virtualhost subdomain - uses Apache basic authentication for Trac authentication. If you want your Trac to be served from e.g. !http://trac.my-proj.my-site.org, then from the folder e.g. /home/trac-for-my-proj, if you used the command trac-admin the-env initenv to create a folder the-env, and you used trac-admin the-env deploy the-deploy to create a folder the-deploy, then first: Create the htpasswd file: {{{#!sh cd /home/trac-for-my-proj/the-env htpasswd -c htpasswd firstuser ### and add more users to it as needed: htpasswd htpasswd seconduser }}} Keep the file above your document root for security reasons. Create this file e.g. (ubuntu) /etc/apache2/sites-enabled/trac.my-proj.my-site.org.conf with the following content: {{{#!apache WSGIApplicationGroup %{GLOBAL} Order deny,allow Allow from all ServerName trac.my-proj.my-site.org DocumentRoot /home/trac-for-my-proj/the-env/htdocs/ WSGIScriptAlias / /home/trac-for-my-proj/the-deploy/cgi-bin/trac.wsgi AuthType Basic AuthName "Trac" AuthUserFile /home/trac-for-my-proj/the-env/htpasswd Require valid-user }}} Note: for subdomains to work you would probably also need to alter /etc/hosts and add A-Records to your host's DNS. == Troubleshooting === Use a recent version Please use either version 1.6, 2.4 or later of mod_wsgi. Versions prior to 2.4 in the 2.X branch have problems with some Apache configurations that use WSGI file wrapper extension. This extension is used in Trac to serve up attachments and static media files such as style sheets. If you are affected by this problem, attachments will appear to be empty and formatting of HTML pages will appear not to work due to style sheet files not loading properly. Another frequent symptom is that binary attachment downloads are truncated. See mod_wsgi tickets [http://code.google.com/p/modwsgi/issues/detail?id=100 #100] and [http://code.google.com/p/modwsgi/issues/detail?id=132 #132]. ''Note: using mod_wsgi 2.5 and Python 2.6.1 gave an Internal Server Error on my system (Apache 2.2.11 and Trac 0.11.2.1). Upgrading to Python 2.6.2 (as suggested [http://www.mail-archive.com/modwsgi@googlegroups.com/msg01917.html here]) solved this for me[[BR]]-- Graham Shanks'' If you plan to use mod_wsgi in embedded mode on Windows or with the MPM worker on Linux, then you will need version 3.4 or greater. See [trac:#10675] for details. === Getting Trac to work nicely with SSPI and 'Require Group' If you have set Trac up on Apache, Win32 and configured SSPI, but added a 'Require group' option to your apache configuration, then the SSPIOmitDomain option is probably not working. If it is not working, your usernames in Trac probably look like 'DOMAIN\user' rather than 'user'. This WSGI script 'fixes' that: {{{#!python import os import trac.web.main os.environ['TRAC_ENV'] = '/usr/local/trac/mysite' os.environ['PYTHON_EGG_CACHE'] = '/usr/local/trac/mysite/eggs' def application(environ, start_response): if "\\" in environ['REMOTE_USER']: environ['REMOTE_USER'] = environ['REMOTE_USER'].split("\\", 1)[1] return trac.web.main.dispatch_request(environ, start_response) }}} === Trac with PostgreSQL When using the mod_wsgi adapter with multiple Trac instances and PostgreSQL (or MySQL?) as the database, the server ''may'' create a lot of open database connections and thus PostgreSQL processes. A somewhat brutal workaround is to disable connection pooling in Trac. This is done by setting poolable = False in trac.db.postgres_backend on the PostgreSQLConnection class. But it is not necessary to edit the source of Trac. The following lines in trac.wsgi will also work: {{{#!python import trac.db.postgres_backend trac.db.postgres_backend.PostgreSQLConnection.poolable = False }}} or {{{#!python import trac.db.mysql_backend trac.db.mysql_backend.MySQLConnection.poolable = False }}} Now Trac drops the connection after serving a page and the connection count on the database will be kept low. //This is not a recommended approach though. See also the notes at the bottom of the [http://code.google.com/p/modwsgi/wiki/IntegrationWithTrac mod_wsgi's IntegrationWithTrac] wiki page.// === Other resources For more troubleshooting tips, see also the [TracModPython#Troubleshooting mod_python troubleshooting] section, as most Apache-related issues are quite similar, plus discussion of potential [http://code.google.com/p/modwsgi/wiki/ApplicationIssues application issues] when using mod_wsgi. The wsgi page also has a [http://code.google.com/p/modwsgi/wiki/IntegrationWithTrac Integration With Trac] document. ---- See also: TracGuide, TracInstall, [wiki:TracFastCgi FastCGI], [wiki:TracModPython ModPython], [trac:TracNginxRecipe TracNginxRecipe] • ## wiki/pages/TracNavigation  r37567 = Trac Navigation The main and meta navigation entries can be customized in some basic ways. The [mainnav] and [metanav] configuration sections can be used to customize the navigation item text and link, change the ordering of the navigation items, or even disable them. === [mainnav] #mainnav-bar [mainnav] corresponds to the '''main navigation bar''', the one containing entries such as ''Wiki'', ''Timeline'', ''Roadmap'', ''Browse Source'' and so on. This navigation bar is meant to access the default page of the main modules enabled in Trac that are accessible for the current user. ** [=#Example Example] ** In the following example we rename the link to WikiStart //Home//, and make the //View Tickets// entry link to a specific report. {{{#!ini [mainnav] wiki.label = Home tickets.href = /report/24 }}} === [metanav] #metanav-bar [metanav] corresponds to the '''meta navigation bar''', by default positioned above the main navigation bar and below the ''Search'' box. It contains the ''Login'', ''Logout'', ''!Help/Guide'' etc. entries. This navigation bar is meant to access some global information about the Trac project and the current user. There is one special entry in the [metanav] section: logout.redirect is the page the user sees after hitting the logout button. The ''!Help/Guide'' link is also hidden in the following example. [[comment(see also #Trac3808)]] ** Example ** {{{#!ini [metanav] help = disabled logout.redirect = wiki/Logout }}} === URL Formats Possible URL formats for .href or .redirect: || '''config''' || '''redirect to''' || || wiki/Logout || /projects/env/wiki/Logout || || http://hostname/ || http://hostname/ || || /projects || /projects || === Ordering #nav-order The order attribute specifies the order in which the navigation items are displayed. This can be particularly useful for plugins that add navigation items. Non-negative floating point values may be used for the order attribute. The navigation items will be arranged from left to right in increasing order. Navigation items without an order attribute are sorted alphabetically by name. The default values are: {{{#!ini [mainnav] browser.order = 4 newticket.order = 6 roadmap.order = 3 search.order = 7 tickets.order = 5 timeline.order = 2 wiki.order = 1 [metanav] about.order = 5 help.order = 4 login.order = 1 logout.order = 2 prefs.order = 3 }}} === Context Navigation #ctxtnav-bar Note that it is still not possible to customize the '''contextual navigation bar''', ie the one usually placed below the main navigation bar. ---- See also: TracInterfaceCustomization, and the [http://trac-hacks.org/wiki/NavAddPlugin TracHacks:NavAddPlugin] or [http://trac-hacks.org/wiki/MenusPlugin TracHacks:MenusPlugin] (still needed for adding entries) • ## wiki/pages/TracNotification  r37662 = Email Notification of Ticket Changes [[TracGuideToc]] Trac supports notification of ticket changes via email. Email notification is useful to keep users up-to-date on tickets/issues of interest, and also provides a convenient way to post all ticket changes to a dedicated mailing list. For example, this is how the [http://lists.edgewall.com/archive/trac-tickets/ Trac-tickets] mailing list is set up. Disabled by default, notification can be activated and configured in [wiki:TracIni trac.ini]. == Receiving Notification Mails When reporting a new ticket or adding a comment, enter a valid email address or your Trac username in the ''reporter'', ''assigned to/owner'' or ''cc'' field. Trac will automatically send you an email when changes are made to the ticket, depending on how notification is configured. === How to use your username to receive notification mails To receive notification mails, you can either enter a full email address or your Trac username. To get notified with a simple username or login, you need to specify a valid email address in the ''Preferences'' page. Alternatively, a default domain name ('''smtp_default_domain''') can be set in the TracIni file, see [#ConfigurationOptions Configuration Options] below. In this case, the default domain will be appended to the username, which can be useful for an "Intranet" kind of installation. When using apache and mod_kerb for authentication against Kerberos / Active Directory, usernames take the form ('''username@EXAMPLE.LOCAL'''). To avoid this being interpreted as an email address, add the Kerberos domain to ('''ignore_domains'''). === Ticket attachment notifications Since 1.0.3 Trac will send notifications when a ticket attachment is added or deleted. Usually attachment notifications will be enabled in an environment by default. To disable the attachment notifications for an environment the TicketAttachmentNotifier component must be disabled: {{{#!ini [components] trac.ticket.notification.TicketAttachmentNotifier = disabled }}} == Configuring SMTP Notification '''Important:''' For TracNotification to work correctly, the [trac] base_url option must be set in [wiki:TracIni trac.ini]. === Configuration Options These are the available options for the [notification] section in trac.ini: [[TracIni(notification)]] === Example Configuration (SMTP) {{{#!ini [notification] smtp_enabled = true smtp_server = mail.example.com smtp_from = notifier@example.com smtp_replyto = myproj@projects.example.com smtp_always_cc = ticketmaster@example.com, theboss+myproj@example.com }}} === Example Configuration (sendmail) {{{#!ini [notification] smtp_enabled = true email_sender = SendmailEmailSender sendmail_path = /usr/sbin/sendmail smtp_from = notifier@example.com smtp_replyto = myproj@projects.example.com smtp_always_cc = ticketmaster@example.com, theboss+myproj@example.com }}} === Subscriber Configuration The default subscriptions are configured in the [notification-subscriber] section in trac.ini: [[TracIni(notification-subscriber)]] Each user can override these defaults in his ''Notifications'' preferences. For example to unsubscribe from notifications for one's own changes and comments, the rule "Never notify: I update a ticket" should be added above other subscription rules. === Customizing the e-mail subject The e-mail subject can be customized with the ticket_subject_template option, which contains a [http://genshi.edgewall.org/wiki/Documentation/text-templates.html Genshi text template] snippet. The default value is: {{{#!genshi$prefix #$ticket.id:$summary }}} The following variables are available in the template: * env: The project environment (see [trac:source:/trunk/trac/env.py env.py]). * prefix: The prefix defined in smtp_subject_prefix. * summary: The ticket summary, with the old value if the summary was edited. * ticket: The ticket model object (see [trac:source:/trunk/trac/ticket/model.py model.py]). Individual ticket fields can be addressed by appending the field name separated by a dot, eg $ticket.milestone. === Customizing the e-mail content The notification e-mail content is generated based on ticket_notify_email.txt in trac/ticket/templates. You can add your own version of this template by adding a ticket_notify_email.txt to the templates directory of your environment. The default looks like this: {{{#!genshi$ticket_body_hdr $ticket_props {% choose ticket.new %}\ {% when True %}\$ticket.description {%   end %}\ {%   otherwise %}\ {%     if changes_body %}\ ${_('Changes (by %(author)s):', author=change.author)}$changes_body {%     end %}\ {%     if changes_descr %}\ {%       if not changes_body and not change.comment and change.author %}\ ${_('Description changed by %(author)s:', author=change.author)} {% end %}\$changes_descr -- {%     end %}\ {%     if change.comment %}\ ${changes_body and _('Comment:') or _('Comment (by %(author)s):', author=change.author)}$change.comment {%     end %}\ {%   end %}\ {% end %}\ -- ${_('Ticket URL: <%(link)s>', link=ticket.link)}$project.name <${project.url or abs_href()}>$project.descr }}} == Sample Email {{{ #42: testing ---------------------------+------------------------------------------------ Id:  42             |      Status:  assigned Component:  report system  |    Modified:  Fri Apr  9 00:04:31 2004 Severity:  major          |   Milestone:  0.9 Priority:  lowest         |     Version:  0.6 Owner:  anonymous      |    Reporter:  jonas@example.com ---------------------------+------------------------------------------------ Changes: * component:  changeset view => search system * priority:  low => highest * owner:  jonas => anonymous * cc:  daniel@example.com => daniel@example.com, jonas@example.com * status:  new => assigned Comment: I'm interested too! -- Ticket URL: My Project }}} == Customizing e-mail content for MS Outlook MS Outlook normally presents plain text e-mails with a variable-width font, and as a result the ticket properties table will most certainly look like a mess in MS Outlook. This can be fixed with some customization of the [#Customizingthee-mailcontent e-mail template]. Replace the following second row in the template: {{{ $ticket_props }}} with this (requires Python 2.6 or later): {{{ -------------------------------------------------------------------------- {% with pv = [(a[0].strip(), a[1].strip()) for a in [b.split(':') for b in [c.strip() for c in ticket_props.replace('|', '\n').splitlines()[1:-1]] if ':' in b]]; sel = ['Reporter', 'Owner', 'Type', 'Status', 'Priority', 'Milestone', 'Component', 'Severity', 'Resolution', 'Keywords'] %}\${'\n'.join('%s\t%s' % (format(p[0]+':', ' <12'), p[1]) for p in pv if p[0] in sel)} {% end %}\ -------------------------------------------------------------------------- }}} The table of ticket properties is replaced with a list of a selection of the properties. A tab character separates the name and value in such a way that most people should find this more pleasing than the default table when using MS Outlook. {{{#!div style="margin: 1em 1.75em; border:1px dotted" {{{#!html #42: testing
--------------------------------------------------------------------------
--------------------------------------------------------------------------
Changes:

* component:  changeset view => search system
* priority:  low => highest
* owner:  jonas => anonymous
* cc:  daniel@example.com =>
daniel@example.com, jonas@example.com
* status:  new => assigned

Comment:
I'm interested too!

--
Ticket URL: <http://example.com/trac/ticket/42>
My Project <http://myproj.example.com/>

• ## wiki/pages/TracRevisionLog

 r37662 = Viewing Revision Logs = [[TracGuideToc]] When you browse the repository, it is always possible to view the ''Revision Log'' that corresponds to the repository path. This displays a list of the most recent changesets in which the current path or any other path below it has been modified. == The Revision Log Form == It is possible to set the revision at which the revision log should start, using the ''View log starting at'' field. An empty value or a value of ''head'' is interpreted as the newest changeset. It is also possible to specify the revision at which the log should stop, using the ''