Changes between Version 5 and Version 6 of Ubuntu-11.04-Subversion
- Timestamp:
- Dec 17, 2010, 4:07:25 PM (13 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ubuntu-11.04-Subversion
v5 v6 64 64 }}} 65 65 66 Start the Subversion server (or use your preferred method): 67 {{{ 68 sudo svnserve -d 69 }}} 70 66 71 === Setup the MySQL database === 67 72 … … 109 114 }}} 110 115 111 You will need to fill in some information, like the project name. Also, it will ask you for the MySQL connection string. Input the following (according to the way we did setup the MySQL database in the step 2.2). 116 You will need to fill in some information, like the project name. Pay attention to the question about the location of the Subversion project. Enter the path as discussed before: 117 {{{ 118 /var/lib/svn/YourProject 119 }}} 120 121 Also, it will ask you for the MySQL connection string. Input the following (according to the way we did setup the MySQL database in the step 2.2). 112 122 {{{ 113 123 mysql://trac:yourpassword@localhost/trac … … 164 174 Again, make sure you give exec perms to the script. 165 175 166 ===== Automatic reference to the SVN changesets in Trac tickets ===== 176 Now Trac will be notified about changes you make to your repository and will make them availables in the timeline. 167 177 168 178 … … 171 181 ==== Set up Trac handling ==== 172 182 183 Apache needs to know how to handle Trac. Use the following block to set up Trac handling: 184 {{{ 185 <Location /projects> #set up Trac handling 186 SetHandler mod_python 187 PythonHandler trac.web.modpython_frontend 188 PythonOption TracEnvParentDir /var/lib/trac 189 PythonOption TracUriRoot /projects 190 </Location> 191 }}} 192 193 Note that it's poiting to the main Trac directory. It means it will expose all of your Trac projects. 194 173 195 ==== Authentication ==== 174 196 175 176 == Workflow examples == 197 In order to allow users to log in Trac, you will need the following section in your Apache configuration: 198 {{{ 199 <Location "/trac/login"> 200 AuthType Basic 201 AuthName "Trac" 202 AuthUserFile /var/tracprojects/.htpasswd 203 Require valid-user 204 </Location> 205 }}} 206 207 Go ahead and restart Apache: 208 {{{ 209 sudo /etc/init.d/apache2 restart 210 }}} 211 212 == Automatic reference to the SVN changesets in Trac tickets == 213 214 Something useful is to reference tickets on your commits. That way you can keep a better track of them and also easly access them from the timeline. 215 216 Make sure you have the following line in your trac.ini configuration file: 217 {{{ 218 tracopt.ticket.commit_updater.* = enabled 219 }}} 220 221 Now, whenever you commit some change related to a ticket, use ''Refs #tn'' to reference this changeset in #tn ticket. For example: 222 {{{ 223 svn commit -m "Refs #123 - added this and that" 224 }}} 225 226 In order to mark a ticket as fixed, use the following: 227 {{{ 228 svn commit -m "Fixes #123 - Removed an infinite loop which was causing the application to freeze" 229 }}}