Rev Author Line No. Line
344 kaklik 1 <?php
130 kaklik 2 # vim:et:ts=3:sts=3:sw=3:fdm=marker:
3  
4 // WebSVN - Subversion repository viewing via the web using PHP
5 // Copyright © 2004-2006 Tim Armes, Matt Sicker
6 //
7 // This program is free software; you can redistribute it and/or modify
8 // it under the terms of the GNU General Public License as published by
9 // the Free Software Foundation; either version 2 of the License, or
10 // (at your option) any later version.
11 //
12 // This program is distributed in the hope that it will be useful,
13 // but WITHOUT ANY WARRANTY; without even the implied warranty of
14 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 // GNU General Public License for more details.
16 //
17 // You should have received a copy of the GNU General Public License
18 // along with this program; if not, write to the Free Software
19 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20 //
21 // --
22 //
23 // config.inc
24 //
25 // Configuration parameters
26  
27 // --- FOLLOW THE INSTRUCTIONS BELOW TO CONFIGURE YOUR SETUP ---
28  
29 // {{{ PLATFORM CONFIGURATION ---
30  
31 // Uncomment the next line if your running a windows server
32 //
33 // $config->setServerIsWindows();
34  
35 // Configure these lines if your commands aren't on your path.
36 //
37 // $config->setSVNCommandPath('Path/to/svn and svnlook/ e.g. c:\\program files\\subversion\\bin');
38 // $config->setDiffPath('Path/to/diff/command/');
39  
40 // For syntax colouring, if option enabled...
41 // $config->setEnscriptPath('Path/to/enscript/command/');
42 // $config->setSedPath('Path/to/sed/command/');
43  
44 // For delivered tarballs, if option enabled...
45 // $config->setTarPath('Path/to/tar/command/');
46  
47 // For delivered GZIP'd files and tarballs, if option enabled...
48 // $config->setGZipPath('Path/to/gzip/command/');
49  
50 // }}}
51  
52 // {{{ REPOSITORY SETUP ---
53  
54 // There are 2 methods for defining the repositiories available on the system. Either you list
55 // them by hand, in which case you can give each one the name of your choice, or you use the
56 // parent path function, in which case the name of the directory is used as the repository name.
57 //
58 // In all cases, you may optionally supply a group name to the repositories. This is useful in the
59 // case that you need to separate your projects. Grouped Repositories are referred to using the
60 // convention GroupName.RepositoryName
61 //
62 // Performance is much better on local repositories (e.g. accessed by file:///). However, you
63 // can also provide an interface onto a remote repository. In this case you should supply the
64 // username and password needed to access it.
65 //
66 // To configure the repositories by hand, copy the appropriate line below, uncomment it and
67 // replace the name and URL of your repository.
68  
69 // Local repositories (without and with optional group):
70 //
71 // $config->addRepository('NameToDisplay', 'URL to repository (e.g. file:///c:/svn/proj)');
72 // $config->addRepository('NameToDisplay', 'URL to repository (e.g. file:///c:/svn/proj)', 'group');
139 root 73 $config->addRepository('MLAB', 'file:///home/MLAB');
365 kaklik 74 $config->addRepository('library', 'file:///home/library');
302 kaklik 75 //$config->addRepository('BlueGrey', 'file:///home/MLAB');
76 //$config->addRepository('Standard', 'file:///home/MLAB');
77 $config->addRepository('svnkaklik', 'file:///home/svnkaklik');
428 kaklik 78 $config->addRepository('svnkaklik', 'file:///home/MLAB_E');//
130 kaklik 79 // Remote repositories (without and with optional group):
80 //
81 // $config->addRepository('NameToDisplay', 'URL (e.g. http://path/to/rep)', NULL, 'username', 'password');
82 // $config->addRepository('NameToDisplay', 'URL (e.g. http://path/to/rep)', 'group', 'username', 'password');
83 //
84 // To use the parent path method, uncomment the newt line and and replace the path with your one. You
85 // can call the function several times if you have several parent paths. Note that in this case the
86 // path is a filesystem path
87 //
88 // $config->parentPath('Path/to/parent (e.g. c:\\svn)');
89  
90 // }}}
91  
92 // {{{ LOOK AND FEEL ---
93 //
94 // Uncomment ONLY the template file that you want.
95  
139 root 96 // $config->setTemplatePath("$locwebsvnreal/templates/Standard/");
130 kaklik 97 // $config->setTemplatePath("$locwebsvnreal/templates/BlueGrey/");
98 // $config->setTemplatePath("$locwebsvnreal/templates/Zinn/");
99  
100 // You may also specify a per repository template file by uncommenting and changing the following
101 // line as necessary. Use the convention "groupname.myrep" if your repository is in a group.
102  
103 // $config->setTemplatePath('$locwebsvnreal/templates/Standard/', 'myrep'); // Access file for myrep
139 root 104 $config->setTemplatePath("$locwebsvnreal/templates/MLAB/", "MLAB");
365 kaklik 105 $config->setTemplatePath("$locwebsvnreal/templates/MLAB/", "library");
302 kaklik 106 //$config->setTemplatePath("$locwebsvnreal/templates/BlueGrey/", "BlueGrey");
107 $config->setTemplatePath("$locwebsvnreal/templates/Standard/", "svnkaklik");
428 kaklik 108 $config->setTemplatePath("$locwebsvnreal/templates/Standard/", "MLAB_E");
130 kaklik 109 // The index page containing the projects may either be displayed as a flat view (the default),
110 // where grouped repositories are displayed as "GroupName.RepName" or as a tree view.
111 // In the case of a tree view, you may choose whether the entire tree is open by default.
112  
113 // $config->useTreeIndex(false); // Tree index, closed by default
114 // $config->useTreeIndex(true); // Tree index, open by default
115  
116 // By default, WebSVN displays a tree view onto the current directory. You can however
117 // choose to display a flat view of the current directory only, which may make the display
118 // load faster. Uncomment this line if you want that.
119  
120 // $config->useFlatView();
121  
122 // }}}
123  
124 // {{{ LANGUAGE SETUP ---
125  
126 // WebSVN uses the iconv module to convert messages from your system's character set to the
127 // UTF-8 output encoding. If you find that your log messages aren't displayed correctly then
128 // you'll need to change the value here.
129 //
130 // You may also specify the character encoding of the repository contents if different from
131 // the system encoding. This is typically the case for windows users, whereby the command
132 // line returns, for example, CP850 encoded strings, whereas the source files are encoded
133 // as iso-8859-1 by Windows based text editors. When display text file, WebSVN will convert
134 // them from the content encoding to the output encoding (UTF-8).
135 //
136 // WebSVN does its best to automate all this, so only use the following if it doesn't work
137 // "out of the box". Uncomment and change one of the examples below.
138 //
139 // $config->setInputEncoding('CP850'); // Encoding of result returned by svn command line, etc.
140 // $config->setContentEncoding('iso-8859-1'); // Content encoding of all your repositories // repositories
141  
142 // You may also specify a content encoding on a per repository basis. Uncomment and copy this
143 // line as necessary.
144 //
145 // $config->setContentEncoding('iso-8859-1', 'MyEnc');
146  
147 // Note for Windows users: To enable iconv you'll need to enable the extension in your php.ini file
148 // AND copy iconv.dll (not php_iconv.dll) to your Windows system folder. In most cases the correct
149 // encoding is set when you call $config->setServerIsWindows();.
150  
151 // Note for *nix users. You'll need to have iconv compiled into your binary. The default input and
152 // output encodings are taken from your locale informations. Override these if they aren't correct.
153  
154 // Uncomment the default language. If you want English then don't do anything here.
155 //
257 kakl 156  
139 root 157 include 'languages/czech.inc';
158 // include 'languages/catalan.inc';
159 // include 'languages/danish.inc';
160 // include 'languages/dutch.inc';
161 // include 'languages/finnish.inc';
162 // include 'languages/french.inc';
163 // include 'languages/german.inc';
164 // include 'languages/japanese.inc';
165 // include 'languages/korean.inc';
166 // include 'languages/norwegian.inc';
167 // include 'languages/polish.inc';
168 // include 'languages/portuguese.inc';
130 kaklik 169 // include 'languages/russian.inc';
139 root 170 // include 'languages/schinese.inc';
171 // include 'languages/slovenian.inc';
172 // include 'languages/spanish.inc';
173 // include 'languages/swedish.inc';
174 // include 'languages/tchinese.inc';
175 // include 'languages/turkish.inc';
130 kaklik 176  
177 // }}}
178  
179 // {{{ MULTIVIEWS ---
180  
181 // Uncomment this line if you want to use MultiView to access the repository by, for example:
182 //
183 // http://servername/wsvn/repname/path/in/repository
184 //
185 // Note: The websvn directory will need to have Multiviews turned on in Apache, and you'll need to configure
186 // wsvn.php
187  
188 // $config->useMultiViews();
189  
190 // }}}
191  
192 // {{{ ACCESS RIGHTS ---
193  
194 // Uncomment this line if you want to use your Subversion access file to control access
195 // rights via WebSVN. For this to work, you'll need to set up the same Apache based authentication
196 // to the WebSVN (or wsvn) directory as you have for Subversion itself. More information can be
197 // found in install.txt
198  
199 // $config->useAuthenticationFile('/path/to/accessfile'); // Global access file
200  
201 // You may also specify a per repository access file by uncommenting and copying the following
202 // line as necessary. Use the convention 'groupname.myrep' if your repository is in a group.
203  
345 kaklik 204 $config->useAuthenticationFile('/home/MLAB/conf/authz', 'MLAB'); // Access file for MLAB
205 $config->useAuthenticationFile('/home/svnkaklik/conf/authz', 'svnkaklik'); // Access file for svnkaklik
130 kaklik 206  
207 // }}}
208  
209 // {{{ FILE CONTENT ---
210 //
211 // You may wish certain file types to be GZIP'd and delieved to the user when clicked apon.
212 // This is useful for binary files and the like that don't display well in a browser window!
213 // Copy, uncomment and modify this line for each extension to which this rule should apply.
214 // (Don't forget the . before the extension. You don't need an index between the []'s).
215 // If you'd rather that the files were delivered uncompressed with the associated MIME type,
216 // then read below.
217 //
218 // $zipped[] = '.dll';
219  
220 // Subversion controlled files have an svn:mime-type property that can
221 // be set on a file indicating its mime type. By default binary files
222 // are set to the generic appcliation/octet-stream, and other files
223 // don't have it set at all. WebSVN also has a built-in list of
224 // associations from file extension to MIME content type. (You can
225 // view this list in setup.inc).
226 //
227 // Determining the content-type: By default, if the svn:mime-type
228 // property exists and is different from application/octet-stream, it
229 // is used. Otherwise, if the built-in list has a contentType entry
230 // for the extension of the file, that is used. Otherwise, if the
231 // svn:mime-type property exists has the generic binary value of
232 // application/octet-stream, the file will be served as a binary
233 // file. Otherwise, the file will be brought up as ASCII text in the
234 // browser window (although this text may optionally be colourised.
235 // See below).
236 //
237 // Uncomment this if you want to ignore any svn:mime-type property on your
238 // files.
239 //
240 // $config->ignoreSvnMimeTypes();
241 //
242 // Uncomment this if you want skip WebSVN's custom mime-type handling
243 //
244 // $config->ignoreWebSVNContentTypes();
245 //
246 // Following the examples below, you can add new associations, modify
247 // the default ones or even delete them entirely (to show them in
248 // ASCII via WebSVN).
249  
250 // $contentType['.c'] = 'plain/text'; // Create a new association
251 // $contentType['.doc'] = 'plain/text'; // Modify an existing one
252 // unset($contentType['.m'] // Remove a default association
253  
254 // }}}
255  
256 // {{{ TARBALLS ---
257  
258 // You need tar and gzip installed on your system. Set the paths above if necessary
259 //
260 // Uncomment the line below to offer a tarball download option across all your
261 // repositories.
262 //
263 $config->allowDownload();
264 //
265 // To change the global option for individual repositories, uncomment and replicate
266 // the required line below (replacing 'myrep' for the name of the repository to be changed).
267 // Use the convention 'groupname.myrep' if your repository is in a group.
268  
269 // $config->allowDownload('myrep'); // Specifically allow downloading for 'myrep'
270 // $config->disallowDownload('myrep'); // Specifically disallow downloading for 'myrep'
271  
272 // You can also choose the minimum directory level from which you'll allow downloading.
273 // A value of zero will allow downloading from the root. 1 will allow downloding of directories
274 // in the root, etc.
275 //
276 // If your project is arranged with trunk, tags and branches at the root level, then a value of 2
277 // would allow the downloading of directories within branches/tags while disallowing the download
278 // of the entire branches or tags directories. This would also stop downloading of the trunk, but
279 // see after for path exceptions.
280 //
281 // Change the line below to set the download level across all your repositories.
282  
265 kakl 283 $config->setMinDownloadLevel(2);
130 kaklik 284  
285 // To change the level for individual repositories, uncomment and replicate
286 // the required line below (replacing 'myrep' for the name of the repository to be changed).
287 // Use the convention 'groupname.myrep' if your repository is in a group.
288  
289 // $config->setMinDownloadLevel(2, 'myrep');
290  
291 // Finally, you may add or remove certain directories (and their contents) either globally
292 // or on a per repository basis. Uncomment and copy the following lines as necessary. Note
293 // that the these are searched in the order than you give them until a match is made (with the
294 // exception that all the per repository exceptions are tested before the global ones). This means
295 // that you must disallow /a/b/c/ before you allow /a/b/ otherwise the allowed match on /a/b/ will
296 // stop any further searching, thereby allowing downloads on /a/b/c/.
297  
298 // Global exceptions possibilties:
299 //
300 // $config->addAllowedDownloadException('/path/to/allowed/directory/');
301 // $config->addDisAllowedDownloadException('/path/to/disallowed/directory/');
302 //
303 // Per repository exception possibilties:
304 // Use the convention 'groupname.myrep' if your repository is in a group.
305 //
306 // $config->addAllowedDownloadException('/path/to/allowed/directory/', 'myrep');
307 // $config->addDisAllowedDownloadException('/path/to/disallowed/directory/', 'myrep');
308  
309 // }}}
310  
311 // {{{ COLOURISATION ---
312  
313 // Uncomment this line if you want to use Enscript to colourise your file listings
314 //
315 // You'll need Enscript version 1.6 or higher AND Sed installed to use this feature.
316 // Set the path above.
317 //
318 // $config->useEnscript();
319  
320 // Enscript need to be told what the contents of a file are so that it can be colourised
321 // correctly. WebSVN includes a predefined list of mappings from file extension to Enscript
322 // file type (viewable in setup.inc).
323 //
324 // Here you should add and other extensions not already listed or redefine the default ones. eg:
325 //
326 // $extEnscript['.pas'] = 'pascal';
327 //
328 // Note that extensions are case sensitive.
329  
330 // }}}
331  
332 // {{{ RSSFEED ---
333  
334 // Uncomment this line if you wish to hide the RSS feed links across all repositories
335 //
267 kakl 336 $config->hideRSS();
130 kaklik 337 //
338 // To change the global option for individual repositories, uncomment and replicate
339 // the required line below (replacing 'myrep' for the name of the repository to be changed).
340 // Use the convention 'groupname.myrep' if your repository is in a group.
341  
342 // $config->hideRSS('myrep'); // Specifically hide RSS links for 'myrep'
343 // $config->showRSS('myrep'); // Specifically show RSS links for 'myrep'
344  
345 // }}}
346  
347 // {{{ BUGTRAQ ---
348  
349 // Uncomment this line if you wish to use bugtraq: properties to show links to your BugTracker
350 // from the log messages.
351 //
352 // $config->useBugtraqProperties();
353 //
354 // To change the global option for individual repositories, uncomment and replicate
355 // the required line below (replacing 'myrep' for the name of the repository to be changed).
356 // Use the convention 'groupname.myrep' if your repository is in a group.
357  
358 // $config->useBugtraqProperties('myrep'); // Specifically use bugtraq properties for 'myrep'
359 // $config->ignoreBugtraqProperties('myrep'); // Specifically ignore bugtraq properties for 'myrep'
360  
361 // }}}
362  
363 // {{{ MISCELLANEOUS ---
364  
365 // Comment out this if you don't have the right to use it. Be warned that you may need it however!
366 set_time_limit(0);
367  
368 // Comment this line to turn off caching of repo information. This will slow down your browsing.
369 $config->setCachingOn();
370  
371 // Number of spaces to expand tabs to in diff/listing view across all repositories
372  
373 $config->expandTabsBy(8);
374  
375 // To change the global option for individual repositories, uncomment and replicate
376 // the required line below (replacing 'myrep' for the name of the repository to be changed).
377 // Use the convention 'groupname.myrep' if your repository is in a group.
378  
379 // $config->expandTabsBy(3, 'myrep'); // Expand Tabs by 3 for repository 'myrep'
380  
381 // For installations without PHP5, a copy of PEAR's PHP Compat library is included.
382 // If you have your own version of Compat you wish to use, go ahead and specify here.
383  
384 // $config->setPHPCompatPath('/usr/share/php/PHP/');
385  
386 // }}}
387 ?>