4988 |
kaklik |
1 |
<?php |
|
|
2 |
// WebSVN - Subversion repository viewing via the web using PHP |
|
|
3 |
// Copyright (C) 2004-2006 Tim Armes |
|
|
4 |
// |
|
|
5 |
// This program is free software; you can redistribute it and/or modify |
|
|
6 |
// it under the terms of the GNU General Public License as published by |
|
|
7 |
// the Free Software Foundation; either version 2 of the License, or |
|
|
8 |
// (at your option) any later version. |
|
|
9 |
// |
|
|
10 |
// This program is distributed in the hope that it will be useful, |
|
|
11 |
// but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
|
12 |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
|
13 |
// GNU General Public License for more details. |
|
|
14 |
// |
|
|
15 |
// You should have received a copy of the GNU General Public License |
|
|
16 |
// along with this program; if not, write to the Free Software |
|
|
17 |
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
|
|
18 |
// |
|
|
19 |
// -- |
|
|
20 |
// |
|
|
21 |
// config.php |
|
|
22 |
// |
|
|
23 |
// Configuration parameters |
|
|
24 |
|
|
|
25 |
// --- FOLLOW THE INSTRUCTIONS BELOW TO CONFIGURE YOUR SETUP --- |
|
|
26 |
|
|
|
27 |
// {{{ PLATFORM CONFIGURATION --- |
|
|
28 |
|
|
|
29 |
// Configure a UTF-8 aware locale to properly convert bytes to characters. |
|
|
30 |
// Otherwise files and directories with non-ASCII encoding are deemed to fail |
|
|
31 |
// with native commands. |
|
|
32 |
// $config->setLocale('C.UTF-8'); |
|
|
33 |
|
|
|
34 |
// Configure the path for Subversion to use for --config-dir |
|
|
35 |
// (e.g. if accepting certificates is required when using repositories via https) |
|
|
36 |
// $config->setSvnConfigDir('/tmp/websvn'); |
|
|
37 |
|
|
|
38 |
// Configure these lines if your commands aren't on your path. |
|
|
39 |
// |
|
|
40 |
// $config->setSvnCommandPath('/path/to/svn/command/'); // e.g. c:\\program files\\subversion\\bin |
|
|
41 |
// $config->setSvnAuthzCommandPath('/path/to/svnauthz/command/'); // e.g. c:\\program files\\subversion\\bin\tools |
|
|
42 |
// $config->setDiffPath('/path/to/diff/command/'); |
|
|
43 |
|
|
|
44 |
// For syntax colouring, if option enabled... |
|
|
45 |
// $config->setEnscriptPath('/path/to/enscript/command/'); |
|
|
46 |
// $config->setSedPath('/path/to/sed/command/'); |
|
|
47 |
|
|
|
48 |
// For delivered tarballs, if option enabled... |
|
|
49 |
// $config->setTarPath('/path/to/tar/command/'); |
|
|
50 |
|
|
|
51 |
// For delivered GZIP'd files and tarballs, if option enabled... |
|
|
52 |
// $config->setGZipPath('/path/to/gzip/command/'); |
|
|
53 |
|
|
|
54 |
// download directory/file zipped ... |
|
|
55 |
// $config->setZipPath('/path/to/zip/command/'); |
|
|
56 |
|
|
|
57 |
// Uncomment this line to trust server certificates |
|
|
58 |
// This may useful if you use self-signed certificates and have no chance to accept the certificate once via cli |
|
|
59 |
// $config->setTrustServerCert(); |
|
|
60 |
|
|
|
61 |
// }}} |
|
|
62 |
|
|
|
63 |
// {{{ REPOSITORY SETUP --- |
|
|
64 |
|
|
|
65 |
// There are 2 methods for defining the repositiories available on the system. |
|
|
66 |
// Either you list them by hand, in which case you can give each one the name of |
|
|
67 |
// your choice, or you use the parent path function, in which case the name of |
|
|
68 |
// the directory is used as the repository name. |
|
|
69 |
// |
|
|
70 |
// In all cases, you may optionally supply a group name to the repositories. |
|
|
71 |
// This is useful in the case that you need to separate your projects. Grouped |
|
|
72 |
// repositories are referred to using the convention GroupName.RepositoryName |
|
|
73 |
// |
|
|
74 |
// You may also optionally specify the URL that clients should use to check out |
|
|
75 |
// a working copy. If used, it must be specified after the group, username, and |
|
|
76 |
// password; if these arguments are not needed, then pass null instead. Consult |
|
|
77 |
// the WebSvnConfig class in include/configclass.php for function details. |
|
|
78 |
// |
|
|
79 |
// Performance is much better on local repositories (e.g. accessed by file://). |
|
|
80 |
// However, you can also provide an interface onto a remote repository. In this |
|
|
81 |
// case you should supply the username and password needed to access it. |
|
|
82 |
// |
|
|
83 |
// To configure the repositories by hand, copy the appropriate line below, |
|
|
84 |
// uncomment it and replace the name and URL of your repository. |
|
|
85 |
|
|
|
86 |
// Local repositories (without and with optional group): |
|
|
87 |
// Note that the local URL to the repository depends on your platform: |
|
|
88 |
// Unix-like: file:///path/to/rep |
|
|
89 |
// Windows: file:///c:/svn/proj |
|
|
90 |
// |
|
|
91 |
// $config->addRepository('NameToDisplay', 'local URL'); |
|
|
92 |
// $config->addRepository('NameToDisplay', 'local URL', 'group'); |
|
|
93 |
// |
|
|
94 |
// Remote repositories (without and with optional group): |
|
|
95 |
// A remote URL looks like http://domain.tld/path/to/rep |
|
|
96 |
// |
|
|
97 |
// $config->addRepository('NameToDisplay', 'remote URL', null, 'username', 'password'); |
|
|
98 |
// $config->addRepository('NameToDisplay', 'remote URL', 'group', 'username', 'password'); |
|
|
99 |
// |
|
|
100 |
// Display Part of a repository as if it was a repository. |
|
|
101 |
// |
|
|
102 |
// Local repositories (without and with optional group): |
|
|
103 |
// |
|
|
104 |
// $config->addRepositorySubpath('NameToDisplay', 'local URL', 'subpath'); |
|
|
105 |
// $config->addRepositorySubpath('NameToDisplay', 'local URL', 'subpath', 'group'); |
|
|
106 |
// |
|
|
107 |
// Remote repositories (without and with optional group): |
|
|
108 |
// |
|
|
109 |
// $config->addRepositorySubpath('NameToDisplay', 'remote URL', 'subpath', null, 'username', 'password'); |
|
|
110 |
// $config->addRepositorySubpath('NameToDisplay', 'remote URL', 'subpath', 'group', 'username', 'password'); |
|
|
111 |
// |
|
|
112 |
// To use the parent path method (without and with optional group), uncomment the next line |
|
|
113 |
// and replace the path with your one. You can call the function several times if you have several parent paths. |
|
|
114 |
// Note that in this case the path is a filesystem path and depends on your platform: |
|
|
115 |
// Unix-like: /path/to/parent |
|
|
116 |
// Windows: c:\\svn |
|
|
117 |
// |
|
|
118 |
// $config->parentPath('filesystem path'); |
|
|
119 |
// $config->parentPath('filesystem path', 'group'); |
|
|
120 |
// |
|
|
121 |
// To exclude a repository from being added by the parentPath method uncomment the next line |
|
|
122 |
// and replace the path with your one. You can call the function several times if you have several paths to exclude. |
|
|
123 |
// |
|
|
124 |
// $config->addExcludedPath('filesystem path of excluded rep'); |
|
|
125 |
// |
|
|
126 |
// To add only a subset of repositories specified by the parent path you can call the function with a pattern. |
|
|
127 |
// |
|
|
128 |
// $config->parentPath('filesystem path', 'group', '/^beginwith/'); |
|
|
129 |
|
|
|
130 |
// }}} |
|
|
131 |
|
|
|
132 |
// {{{ LOOK AND FEEL --- |
|
|
133 |
// |
|
|
134 |
// Add custom template paths or comment out templates to modify the list of user selectable templates. |
|
|
135 |
// The first added template serves as a default. |
|
|
136 |
|
|
|
137 |
$config->addTemplatePath($locwebsvnreal.'/templates/calm/'); |
|
|
138 |
$config->addTemplatePath($locwebsvnreal.'/templates/BlueGrey/'); |
|
|
139 |
$config->addTemplatePath($locwebsvnreal.'/templates/Elegant/'); |
|
|
140 |
|
|
|
141 |
// You may also specify a default template by uncommenting and changing the following line as necessary. |
|
|
142 |
// If no default template is set the first added template is used. |
|
|
143 |
|
|
|
144 |
// $config->setTemplatePath($locwebsvnreal.'/templates/Elegant/'); |
|
|
145 |
|
|
|
146 |
// You may also specify a per repository fixed template by uncommenting and changing the following |
|
|
147 |
// line as necessary. Use the convention 'groupname.myrep' if your repository is in a group. |
|
|
148 |
|
|
|
149 |
// $config->setTemplatePath($locwebsvnreal.'/templates/Elegant/', 'myrep'); |
|
|
150 |
|
|
|
151 |
// The index page containing the projects may either be displayed as a flat view (the default), |
|
|
152 |
// where grouped repositories are displayed as 'GroupName.RepName' or as a tree view. |
|
|
153 |
// In the case of a tree view, you may choose whether the entire tree is open by default. |
|
|
154 |
|
|
|
155 |
// $config->useTreeIndex(false); // Tree index, closed by default |
|
|
156 |
// $config->useTreeIndex(true); // Tree index, open by default |
|
|
157 |
|
|
|
158 |
// By default, WebSVN displays a tree view onto the current directory. You can however |
|
|
159 |
// choose to display a flat view of the current directory only, which may make the display |
|
|
160 |
// load faster. Uncomment this line if you want that. |
|
|
161 |
|
|
|
162 |
// $config->useFlatView(); |
|
|
163 |
|
|
|
164 |
// By default, WebSVN displays subdirectories first and than the files of a directory, |
|
|
165 |
// both alphabetically sorted. |
|
|
166 |
// To use alphabetic order independent of directories and files uncomment this line. |
|
|
167 |
|
|
|
168 |
// $config->setAlphabeticOrder(true); |
|
|
169 |
|
|
|
170 |
// By default, WebSVN loads parent path directories and then on user click other, |
|
|
171 |
// This options loads the entire directory in one go and allows to browse without delay. |
|
|
172 |
// By default all will be collapsed to root directory and can be expanded. |
|
|
173 |
// The performance will be impacted as it takes time to load up all the things in the |
|
|
174 |
// repository. Once loaded directory exapansion is instantaneous. |
|
|
175 |
// The alphabetical order is applied to all directory and files. |
|
|
176 |
// This means that grouping of all dirs together and all files together is NOT supported currently! |
|
|
177 |
// The files and directories are shown as is with a mixture of files and folders. |
|
|
178 |
|
|
|
179 |
// $config->setLoadAllRepos(true); |
|
|
180 |
|
|
|
181 |
// By default, WebSVN displays the information of the last modification |
|
|
182 |
// (revision, age and author) for each repository in an extra column. |
|
|
183 |
// To disable that uncomment this line. |
|
|
184 |
|
|
|
185 |
// $config->setShowLastModInIndex(false); |
|
|
186 |
|
|
|
187 |
// By default, WebSVN displays the information of the last modification |
|
|
188 |
// (revision, age and author) for each file and directory in an extra column. |
|
|
189 |
// To disable that uncomment this line. |
|
|
190 |
|
|
|
191 |
// $config->setShowLastModInListing(false); |
|
|
192 |
|
|
|
193 |
// By default, WebSVN displays the age of the last modification. |
|
|
194 |
// Alternativly the date of the last modification can be shown. |
|
|
195 |
// To show dates instead of ages uncomment this line. |
|
|
196 |
|
|
|
197 |
// $config->setShowAgeInsteadOfDate(false); |
|
|
198 |
|
|
|
199 |
// By default, WebSVN displays the a form to select an other repository. |
|
|
200 |
// If you have a lot of repositories this slows done the script considerably. |
|
|
201 |
// To disable that uncomment this line. |
|
|
202 |
|
|
|
203 |
// $config->setShowRepositorySelectionForm(false); |
|
|
204 |
|
|
|
205 |
// By default, WebSVN does not ignore whitespaces when showing diffs. |
|
|
206 |
// To enable ignoring whitespaces in diffs per default uncomment this line. |
|
|
207 |
|
|
|
208 |
// $config->setIgnoreWhitespacesInDiff(true); |
|
|
209 |
|
|
|
210 |
// }}} |
|
|
211 |
|
|
|
212 |
// {{{ LANGUAGE SETUP --- |
|
|
213 |
|
|
|
214 |
// Set the default language. If you want English then don't do anything here. |
|
|
215 |
// |
|
|
216 |
// $config->setDefaultLanguage('en'); |
|
|
217 |
|
|
|
218 |
// Ignore the user supplied accepted languages to choose reasonable default language. |
|
|
219 |
// If you want to force the default language - regardless of the client - uncomment the following line. |
|
|
220 |
// |
|
|
221 |
// $config->ignoreUserAcceptedLanguages(); |
|
|
222 |
|
|
|
223 |
// }}} |
|
|
224 |
|
|
|
225 |
// {{{ MULTIVIEWS --- |
|
|
226 |
|
|
|
227 |
// Uncomment this line if you want to use MultiView to access the repository by, for example: |
|
|
228 |
// |
|
|
229 |
// http://servername/browse/repname/path/in/repository |
|
|
230 |
// |
|
|
231 |
// Note: The websvn directory will need to have Multiviews turned on in Apache, and you'll need to configure browse.php |
|
|
232 |
|
|
|
233 |
// $config->useMultiViews(); |
|
|
234 |
|
|
|
235 |
// }}} |
|
|
236 |
|
|
|
237 |
// {{{ ACCESS RIGHTS --- |
|
|
238 |
|
|
|
239 |
// Uncomment this line if you want to use your Subversion access file to control access |
|
|
240 |
// rights via WebSVN. For this to work, you'll need to set up the same Apache based authentication |
|
|
241 |
// to the WebSVN (or browse) directory as you have for Subversion itself. More information can be |
|
|
242 |
// found in install.txt |
|
|
243 |
|
|
|
244 |
// $config->useAccessFile('/path/to/accessfile'); // Global access file |
|
|
245 |
|
|
|
246 |
// You may also specify a per repository access file by uncommenting and copying the following |
|
|
247 |
// line as necessary. Use the convention 'groupname.myrep' if your repository is in a group. |
|
|
248 |
|
|
|
249 |
// $config->useAccessFile('/path/to/accessfile', 'myrep'); // Access file for myrep |
|
|
250 |
|
|
|
251 |
// Uncomment this line if you want to prevent search bots to index the WebSVN pages. |
|
|
252 |
|
|
|
253 |
// $config->setBlockRobots(); |
|
|
254 |
|
|
|
255 |
// }}} |
|
|
256 |
|
|
|
257 |
// {{{ FILE CONTENT --- |
|
|
258 |
// |
|
|
259 |
// You may wish certain file types to be GZIP'd and delieved to the user when clicked apon. |
|
|
260 |
// This is useful for binary files and the like that don't display well in a browser window! |
|
|
261 |
// Copy, uncomment and modify this line for each extension to which this rule should apply. |
|
|
262 |
// (Don't forget the . before the extension. You don't need an index between the []'s). |
|
|
263 |
// If you'd rather that the files were delivered uncompressed with the associated MIME type, |
|
|
264 |
// then read below. |
|
|
265 |
// |
|
|
266 |
// $zipped[] = '.dll'; |
|
|
267 |
|
|
|
268 |
// Subversion controlled files have an svn:mime-type property that can |
|
|
269 |
// be set on a file indicating its mime type. By default binary files |
|
|
270 |
// are set to the generic appcliation/octet-stream, and other files |
|
|
271 |
// don't have it set at all. WebSVN also has a built-in list of |
|
|
272 |
// associations from file extension to MIME content type. (You can |
|
|
273 |
// view this list in setup.php). |
|
|
274 |
// |
|
|
275 |
// Determining the content-type: By default, if the svn:mime-type |
|
|
276 |
// property exists and is different from application/octet-stream, it |
|
|
277 |
// is used. Otherwise, if the built-in list has a contentType entry |
|
|
278 |
// for the extension of the file, that is used. Otherwise, if the |
|
|
279 |
// svn:mime-type property exists has the generic binary value of |
|
|
280 |
// application/octet-stream, the file will be served as a binary |
|
|
281 |
// file. Otherwise, the file will be brought up as ASCII text in the |
|
|
282 |
// browser window (although this text may optionally be colourised. |
|
|
283 |
// See below). |
|
|
284 |
// |
|
|
285 |
// Uncomment this if you want to ignore any svn:mime-type property on your |
|
|
286 |
// files. |
|
|
287 |
// |
|
|
288 |
// $config->ignoreSvnMimeTypes(); |
|
|
289 |
// |
|
|
290 |
// Uncomment this if you want skip WebSVN's custom mime-type handling |
|
|
291 |
// |
|
|
292 |
// $config->ignoreWebSVNContentTypes(); |
|
|
293 |
// |
|
|
294 |
// Following the examples below, you can add new associations, modify |
|
|
295 |
// the default ones or even delete them entirely (to show them in |
|
|
296 |
// ASCII via WebSVN). |
|
|
297 |
|
|
|
298 |
// $contentType['.c'] = 'text/plain'; // Create a new association |
|
|
299 |
// $contentType['.doc'] = 'text/plain'; // Modify an existing one |
|
|
300 |
// unset($contentType['.m']); // Remove a default association |
|
|
301 |
|
|
|
302 |
// If you want to selectively override one or more MIME types to display inline |
|
|
303 |
// (e.g., the svn:mime-type property is something like text/plain or text/xml, or |
|
|
304 |
// the file extension matches an entry in $contentType), you can choose to ignore |
|
|
305 |
// one or more specific MIME types. This approach is finer-grained than ignoring |
|
|
306 |
// all svn:mime-type properties, and displaying matching files inline such that |
|
|
307 |
// they are highlighted correctly. (Regular expression matching is used.) |
|
|
308 |
|
|
|
309 |
$config->addInlineMimeType('text/plain'); |
|
|
310 |
// $config->addInlineMimeType('text/*'); |
|
|
311 |
|
|
|
312 |
// }}} |
|
|
313 |
|
|
|
314 |
// {{{ TARBALLS --- |
|
|
315 |
|
|
|
316 |
// You need tar and gzip installed on your system. Set the paths above if necessary |
|
|
317 |
// |
|
|
318 |
// Uncomment the line below to offer a tarball download option across all your |
|
|
319 |
// repositories. |
|
|
320 |
// |
|
|
321 |
// $config->allowDownload(); |
|
|
322 |
// |
|
|
323 |
// Set download modes |
|
|
324 |
// $config->setDefaultFileDlMode('plain'); |
|
|
325 |
// $config->setDefaultDirectoryDlMode('gzip'); |
|
|
326 |
// |
|
|
327 |
// To change the global option for individual repositories, uncomment and replicate |
|
|
328 |
// the appropriate line below (replacing 'myrep' with the name of the repository). |
|
|
329 |
// Use the convention 'groupname.myrep' if your repository is in a group. |
|
|
330 |
|
|
|
331 |
// $config->allowDownload('myrep'); // Specifically allow downloading for 'myrep' |
|
|
332 |
// $config->disallowDownload('myrep'); // Specifically disallow downloading for 'myrep' |
|
|
333 |
|
|
|
334 |
// You can also choose the minimum directory level from which you'll allow downloading. |
|
|
335 |
// A value of zero will allow downloading from the root. 1 will allow downloding of directories |
|
|
336 |
// in the root, etc. |
|
|
337 |
// |
|
|
338 |
// If your project is arranged with trunk, tags and branches at the root level, then a value of 2 |
|
|
339 |
// would allow the downloading of directories within branches/tags while disallowing the download |
|
|
340 |
// of the entire branches or tags directories. This would also stop downloading of the trunk, but |
|
|
341 |
// see after for path exceptions. |
|
|
342 |
// |
|
|
343 |
// Change the line below to set the download level across all your repositories. |
|
|
344 |
|
|
|
345 |
$config->setMinDownloadLevel(2); |
|
|
346 |
|
|
|
347 |
// To change the level for individual repositories, uncomment and replicate |
|
|
348 |
// the appropriate line below (replacing 'myrep' with the name of the repository). |
|
|
349 |
// Use the convention 'groupname.myrep' if your repository is in a group. |
|
|
350 |
|
|
|
351 |
// $config->setMinDownloadLevel(2, 'myrep'); |
|
|
352 |
|
|
|
353 |
// Finally, you may add or remove certain directories (and their contents) either globally |
|
|
354 |
// or on a per repository basis. Uncomment and copy the following lines as necessary. Note |
|
|
355 |
// that the these are searched in the order than you give them until a match is made (with the |
|
|
356 |
// exception that all the per repository exceptions are tested before the global ones). This means |
|
|
357 |
// that you must disallow /a/b/c/ before you allow /a/b/ otherwise the allowed match on /a/b/ will |
|
|
358 |
// stop any further searching, thereby allowing downloads on /a/b/c/. |
|
|
359 |
|
|
|
360 |
// Global exceptions possibilties: |
|
|
361 |
// |
|
|
362 |
// $config->addAllowedDownloadException('/path/to/allowed/directory/'); |
|
|
363 |
// $config->addDisAllowedDownloadException('/path/to/disallowed/directory/'); |
|
|
364 |
// |
|
|
365 |
// Per repository exception possibilties: |
|
|
366 |
// Use the convention 'groupname.myrep' if your repository is in a group. |
|
|
367 |
// |
|
|
368 |
// $config->addAllowedDownloadException('/path/to/allowed/directory/', 'myrep'); |
|
|
369 |
// $config->addDisAllowedDownloadException('/path/to/disallowed/directory/', 'myrep'); |
|
|
370 |
|
|
|
371 |
// }}} |
|
|
372 |
|
|
|
373 |
// {{{ COLOURISATION --- |
|
|
374 |
|
|
|
375 |
// Uncomment this line if you want to use Enscript to colourise your file listings |
|
|
376 |
// |
|
|
377 |
// You'll need Enscript version 1.6 or higher AND Sed installed to use this feature. |
|
|
378 |
// Set the path above. |
|
|
379 |
// |
|
|
380 |
// If you have version 1.6.3 or newer use the following line. |
|
|
381 |
// |
|
|
382 |
// $config->useEnscript(); |
|
|
383 |
// |
|
|
384 |
// If you have version 1.6.2 or older use the following line. |
|
|
385 |
// |
|
|
386 |
// $config->useEnscript(true); |
|
|
387 |
|
|
|
388 |
// Enscript need to be told what the contents of a file are so that it can be colourised |
|
|
389 |
// correctly. WebSVN includes a predefined list of mappings from file extension to Enscript |
|
|
390 |
// file type (viewable in setup.php). |
|
|
391 |
// |
|
|
392 |
// Here you should add and other extensions not already listed or redefine the default ones. eg: |
|
|
393 |
// |
|
|
394 |
// $extEnscript['.pas'] = 'pascal'; |
|
|
395 |
// |
|
|
396 |
// Note that extensions are case sensitive. |
|
|
397 |
|
|
|
398 |
// Uncomment this line if you want to use GeSHi to colourise your file listings |
|
|
399 |
// |
|
|
400 |
// $config->useGeshi(); |
|
|
401 |
// $config->setGeshiPath('/usr/share/php-geshi'); // optional. Use if you have Geshi installed without PEAR/Composer |
|
|
402 |
|
|
|
403 |
// GeSHi need to be told what the contents of a file are so that it can be colourised |
|
|
404 |
// correctly. WebSVN includes a predefined list of mappings from file extension to GeSHi |
|
|
405 |
// languages (viewable in setup.php). |
|
|
406 |
// |
|
|
407 |
// Here you should add and other extensions not already listed or redefine the default ones. eg: |
|
|
408 |
// |
|
|
409 |
// $extGeshi['pascal'] = array('p', 'pas'); |
|
|
410 |
// |
|
|
411 |
// Note that extensions are case sensitive. |
|
|
412 |
|
|
|
413 |
// }}} |
|
|
414 |
|
|
|
415 |
// {{{ Markdown Render |
|
|
416 |
|
|
|
417 |
// Uncomment this line if you want to enable Markdown Rendering of README.md file in the path. |
|
|
418 |
// You will need the Parsedown.php (https://github.com/erusev/parsedown) library for this to work. |
|
|
419 |
// This will look for README.md file on the path and render it. |
|
|
420 |
// The name of "README.md" isn't configurable for now to simply follow GitHub's conventions. |
|
|
421 |
|
|
|
422 |
// $config->useParsedown(); |
|
|
423 |
// $config->setParsedownPath('/usr/share/php/Parsedown/'); // optional. Use if you have Parsedown installed without PEAR/Composer |
|
|
424 |
|
|
|
425 |
// }}} |
|
|
426 |
|
|
|
427 |
// {{{ RSSFEED --- |
|
|
428 |
|
|
|
429 |
// Uncomment this line to hide the RSS feed links across all repositories |
|
|
430 |
|
|
|
431 |
// $config->setRssEnabled(false); |
|
|
432 |
|
|
|
433 |
// To override the global setting for individual repositories, uncomment and replicate |
|
|
434 |
// the appropriate line below (replacing 'myrep' with the name of the repository). |
|
|
435 |
// Use the convention 'groupname.myrep' if your repository is in a group. |
|
|
436 |
|
|
|
437 |
// $config->setRssEnabled(false, 'myrep'); |
|
|
438 |
// $config->setRssEnabled(true, 'myrep'); |
|
|
439 |
|
|
|
440 |
// Uncomment this line to enable caching RSS feeds across all repositories |
|
|
441 |
// This may create a large number of cache files which are currently not garbaged automatically |
|
|
442 |
|
|
|
443 |
// $config->setRssCachingEnabled(true); |
|
|
444 |
|
|
|
445 |
// To override the global setting for individual repositories, uncomment and replicate |
|
|
446 |
// the appropriate line below (replacing 'myrep' with the name of the repository). |
|
|
447 |
// Use the convention 'groupname.myrep' if your repository is in a group. |
|
|
448 |
|
|
|
449 |
// $config->setRssCachingEnabled(true, 'myrep'); |
|
|
450 |
// $config->setRssCachingEnabled(false, 'myrep'); |
|
|
451 |
|
|
|
452 |
// Uncomment this line to change the maximum number of RSS entries to display across all repositories |
|
|
453 |
|
|
|
454 |
// $config->setRssMaxEntries(50); |
|
|
455 |
|
|
|
456 |
// To override the global setting for individual repositories, uncomment and replicate |
|
|
457 |
// the line below (replacing 'myrep' with the name of the repository). |
|
|
458 |
// Use the convention 'groupname.myrep' if your repository is in a group. |
|
|
459 |
|
|
|
460 |
// $config->setRssMaxEntries(50, 'myrep'); |
|
|
461 |
|
|
|
462 |
// }}} |
|
|
463 |
|
|
|
464 |
// {{{ SHOW CHANGED FILES IN LOG --- |
|
|
465 |
|
|
|
466 |
// Uncomment this line to show changed files on log.php by default. The normal |
|
|
467 |
// behavior is to do this only if the "Show changed files" link is clicked. This |
|
|
468 |
// setting reverses the default action but still allows hiding changed files. |
|
|
469 |
|
|
|
470 |
// $config->setLogsShowChanges(true); |
|
|
471 |
|
|
|
472 |
// To override the global setting for individual repositories, uncomment and replicate |
|
|
473 |
// the appropriate line below (replacing 'myrep' with the name of the repository). |
|
|
474 |
// Use the convention 'groupname.myrep' if your repository is in a group. |
|
|
475 |
|
|
|
476 |
// $config->setLogsShowChanges(true, 'myrep'); |
|
|
477 |
// $config->setLogsShowChanges(false, 'myrep'); |
|
|
478 |
|
|
|
479 |
// }}} |
|
|
480 |
|
|
|
481 |
// {{{ BUGTRAQ --- |
|
|
482 |
|
|
|
483 |
// Uncomment this line to use bugtraq: properties to show links to your BugTracker |
|
|
484 |
// from log messages. |
|
|
485 |
|
|
|
486 |
// $config->setBugtraqEnabled(true); |
|
|
487 |
|
|
|
488 |
// To override the global setting for individual repositories, uncomment and replicate |
|
|
489 |
// the appropriate line below (replacing 'myrep' with the name of the repository). |
|
|
490 |
// Use the convention 'groupname.myrep' if your repository is in a group. |
|
|
491 |
|
|
|
492 |
// $config->setBugtraqEnabled(true, 'myrep'); |
|
|
493 |
// $config->setBugtraqEnabled(false, 'myrep'); |
|
|
494 |
|
|
|
495 |
// Usually the information to extract the bugtraq information and generate links are |
|
|
496 |
// stored in SVN properties starting with 'bugtraq:': |
|
|
497 |
// namely 'bugtraq:message', 'bugtraq:logregex', 'bugtraq:url' and 'bugtraq:append'. |
|
|
498 |
// To override the SVN properties globally or for individual repositories, uncomment |
|
|
499 |
// the appropriate line below (replacing 'myrep' with the name of the repository). |
|
|
500 |
|
|
|
501 |
// $config->setBugtraqProperties('bug #%BUGID%', 'issues? (\d+)([, ] *(\d+))*'."\n".'(\d+)', 'http://www.example.com/issues/show_bug.cgi?id=%BUGID%', false); |
|
|
502 |
// $config->setBugtraqProperties('bug #%BUGID%', 'issues? (\d+)([, ] *(\d+))*'."\n".'(\d+)', 'http://www.example.com/issues/show_bug.cgi?id=%BUGID%', false, 'myrep'); |
|
|
503 |
|
|
|
504 |
// }}} |
|
|
505 |
|
|
|
506 |
// {{{ MISCELLANEOUS --- |
|
|
507 |
|
|
|
508 |
// Comment out this if you don't have the right to use it. Be warned that you may need it however! |
|
|
509 |
set_time_limit(0); |
|
|
510 |
|
|
|
511 |
// Change the line below to specify a temporary directory other than the one PHP uses. |
|
|
512 |
|
|
|
513 |
// $config->setTempDir('temp'); |
|
|
514 |
|
|
|
515 |
// Number of spaces to expand tabs to in diff/listing view across all repositories |
|
|
516 |
|
|
|
517 |
$config->expandTabsBy(8); |
|
|
518 |
|
|
|
519 |
// To override the global setting for individual repositories, uncomment and replicate |
|
|
520 |
// the line below (replacing 'myrep' with the name of the repository). |
|
|
521 |
// Use the convention 'groupname.myrep' if your repository is in a group. |
|
|
522 |
|
|
|
523 |
// $config->expandTabsBy(3, 'myrep'); // Expand Tabs by 3 for repository 'myrep' |
|
|
524 |
|
|
|
525 |
// Change the name of the breadcrumb root-phrase to that of the current repo? |
|
|
526 |
// $config->setBreadcrumbRepoRootAsRepo(true); |
|
|
527 |
|
|
|
528 |
// }}} |