| 143 | | Note that in this case you won't have the possibility to run a localized version of Trac; |
| 144 | | either use a released version or install from source |
| | 145 | |
| | 146 | - upgrade to the latest trunk development version (0.13dev): |
| | 147 | {{{ |
| | 148 | easy_install -U Trac==dev |
| | 149 | }}} |
| | 150 | |
| | 151 | For upgrades, reading the TracUpgrade page is mandatory, of course. |
| | 152 | |
| | 153 | === From source |
| | 154 | If you want more control, you can download the source in archive form, or do a checkout from one of the official [[Trac:TracRepositories|source code repositories]]. |
| | 155 | |
| | 156 | Be sure to have the prerequisites already installed. You can also obtain the Genshi and Babel source packages from http://www.edgewall.org and follow for them a similar installation procedure, or you can just easy_install those, see [#Usingeasy_install above]. |
| | 157 | |
| | 158 | Once you've unpacked the Trac archive or performed the checkout, move in the top-level folder and do: |
| | 159 | {{{ |
| | 160 | $ python ./setup.py install |
| | 161 | }}} |
| | 162 | |
| | 163 | ''You'll need root permissions or equivalent for this step.'' |
| | 164 | |
| | 165 | This will byte-compile the python source code and install it as an .egg file or folder in the `site-packages` directory |
| | 166 | of your Python installation. The .egg will also contain all other resources needed by standard Trac, such as htdocs and templates. |
| | 167 | |
| | 168 | The script will also install the [wiki:TracAdmin trac-admin] command-line tool, used to create and maintain [wiki:TracEnvironment project environments], as well as the [wiki:TracStandalone tracd] standalone server. |
| | 169 | |
| | 170 | 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): |
| | 171 | {{{ |
| | 172 | $ python ./setup.py install |
| | 173 | }}} |
| | 174 | Alternatively, you can do a `bdist_egg` and copy the .egg from dist/ to the place of your choice, or you can create a Windows installer (`bdist_wininst`). |
| | 175 | |
| | 176 | === Advanced Options === |
| | 177 | |
| | 178 | To install Trac to a custom location, or find out about other advanced installation options, run: |
| | 179 | {{{ |
| | 180 | easy_install --help |
| | 181 | }}} |
| | 182 | |
| | 183 | Also see [http://docs.python.org/inst/inst.html Installing Python Modules] for detailed information. |
| | 184 | |
| | 185 | Specifically, you might be interested in: |
| | 186 | {{{ |
| | 187 | easy_install --prefix=/path/to/installdir |
| | 188 | }}} |
| | 189 | or, if installing Trac to a Mac OS X system: |
| | 190 | {{{ |
| | 191 | easy_install --prefix=/usr/local --install-dir=/Library/Python/2.5/site-packages |
| | 192 | }}} |
| | 193 | Note: If installing on Mac OS X 10.6 running {{{ easy_install http://svn.edgewall.org/repos/trac/trunk }}} will install into {{{ /usr/local }}} and {{{ /Library/Python/2.6/site-packages }}} by default |
| | 194 | |
| | 195 | The above will place your `tracd` and `trac-admin` commands into `/usr/local/bin` and will install the Trac libraries and dependencies into `/Library/Python/2.5/site-packages`, which is Apple's preferred location for third-party Python application installations. |
| 164 | | pip will automatically resolve all dependencies (like Genshi, pygments, etc.) and download the latest packages on pypi.python.org and create a self contained installation in /opt/user/trac |
| 165 | | |
| 166 | | 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) |
| | 215 | pip will automatically resolve all dependencies (like Genshi, pygments, etc.) and download the latest packages on pypi.python.org and create a self contained installation in /opt/user/trac . |
| | 216 | |
| | 217 | 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) |
| 170 | | |
| 171 | | |
| 172 | | === From source |
| 173 | | Of course, using the python-typical setup at the top of the source directory also works. |
| 174 | | |
| 175 | | You can obtain the source for a .tar.gz or .zip file corresponding to a release (e.g. Trac-0.12.tar.gz), or you can get the source directly from the repository (see [trac:SubversionRepository] for details). |
| 176 | | |
| 177 | | {{{ |
| 178 | | $ python ./setup.py install |
| 179 | | }}} |
| 180 | | |
| 181 | | ''You'll need root permissions or equivalent for this step.'' |
| 182 | | |
| 183 | | This will byte-compile the python source code and install it as an .egg file or folder in the `site-packages` directory |
| 184 | | of your Python installation. The .egg will also contain all other resources needed by standard Trac, such as htdocs and templates. |
| 185 | | |
| 186 | | The script will also install the [wiki:TracAdmin trac-admin] command-line tool, used to create and maintain [wiki:TracEnvironment project environments], as well as the [wiki:TracStandalone tracd] standalone server. |
| 187 | | |
| 188 | | 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): |
| 189 | | {{{ |
| 190 | | $ python ./setup.py install |
| 191 | | }}} |
| 192 | | Alternatively, you can do a `bdist_egg` and copy the .egg from dist/ to the place of your choice, or you can create a Windows installer (`bdist_wininst`). |
| 193 | | |
| 194 | | === Advanced Options === |
| 195 | | |
| 196 | | To install Trac to a custom location, or find out about other advanced installation options, run: |
| 197 | | {{{ |
| 198 | | easy_install --help |
| 199 | | }}} |
| 200 | | |
| 201 | | Also see [http://docs.python.org/inst/inst.html Installing Python Modules] for detailed information. |
| 202 | | |
| 203 | | Specifically, you might be interested in: |
| 204 | | {{{ |
| 205 | | easy_install --prefix=/path/to/installdir |
| 206 | | }}} |
| 207 | | or, if installing Trac to a Mac OS X system: |
| 208 | | {{{ |
| 209 | | easy_install --prefix=/usr/local --install-dir=/Library/Python/2.5/site-packages |
| 210 | | }}} |
| 211 | | Note: If installing on Mac OS X 10.6 running {{{ easy_install http://svn.edgewall.org/repos/trac/trunk }}} will install into {{{ /usr/local }}} and {{{ /Library/Python/2.6/site-packages }}} by default |
| 212 | | |
| 213 | | The above will place your `tracd` and `trac-admin` commands into `/usr/local/bin` and will install the Trac libraries and dependencies into `/Library/Python/2.5/site-packages`, which is Apple's preferred location for third-party Python application installations. |