Annotation of cvsweb/cvsweb.conf, Revision 3.27
3.1 knu 1: # -*-perl-*-
2: # Configuration of cvsweb.cgi, the
3: # CGI interface to CVS Repositories.
4: #
5: # (c) 1998-1999 H. Zeller <zeller@think.de>
6: # 1999 H. Nordstrom <hno@hem.passagen.se>
3.22 knu 7: # 2000-2001 A. MUSHA <knu@FreeBSD.org>
3.1 knu 8: # based on work by Bill Fenner <fenner@FreeBSD.org>
3.27 ! knu 9: # $Id: cvsweb.conf,v 3.29 2001/07/23 09:14:52 hzeller Exp $
! 10: # $Idaemons: /home/cvs/cvsweb/cvsweb.conf,v 3.26 2001/08/01 09:32:22 knu Exp $
3.1 knu 11: #
12: ###
13:
3.19 knu 14: # Set the path for the following commands:
15: # uname, cvs, rlog, rcsdiff
16: # gzip (if you enable $allow_compress)
3.25 knu 17: # tar, rm, zip (if you enable $allow_tar)
3.19 knu 18: $command_path = '/bin:/usr/bin:/usr/local/bin';
19:
20: # Search the above directories for each command
3.25 knu 21: for (qw(uname cvs rlog rcsdiff gzip tar rm zip)) {
3.26 knu 22: $CMD{$_} = search_path($_);
3.19 knu 23: }
24:
25: # The name of the operating system implementation
3.21 knu 26: chomp($uname = `$CMD{uname}`);
3.19 knu 27:
3.1 knu 28: ##############
29: # CVS Root
30: ##############
31: # CVSweb can handle several CVS-Repositories
32: # at once. Enter a short symbolic names and the
33: # full path of these repositories here.
34: # NOTE that the symbolic names may not contain
35: # whitespaces.
36: # Note, that cvsweb.cgi currently needs to have physical access
37: # to the CVS repository so :pserver:someone@xyz.com:/data/cvsroot
38: # won't work!
39:
3.17 knu 40: # 'symbolic_name' => ['name_to_display', 'path_to_the_actual_repository']
41: # Listed in the order specified:
42: @CVSrepositories = (
3.26 knu 43: 'local' => ['Local Repository', '/home/cvs'],
44: # 'freebsd' => ['FreeBSD', '/home/ncvs'],
45: # 'openbsd' => ['OpenBSD', '/home/ncvs'],
46: # 'netbsd' => ['NetBSD', '/home/ncvs'],
47: # 'ruby' => ['Ruby', '/var/anoncvs/ruby'],
48: );
3.1 knu 49:
50: # This tree is enabled by default when
51: # you enter the page
3.26 knu 52: $cvstreedefault = $CVSrepositories[2 * 0]; # The first one
3.1 knu 53:
54: ##############
3.15 knu 55: # Bug tracking system options
56: # ("PR" means Problem Report, as in GNATS)
3.1 knu 57: ##############
3.15 knu 58: #@prcategories = qw(
3.26 knu 59: # advocacy
60: # alpha
61: # bin
62: # conf
63: # docs
64: # gnu
65: # i386
66: # kern
67: # misc
68: # pending
69: # ports
70: # sparc
71: #);
72:
3.15 knu 73: #
74: #$prcgi = "http://www.FreeBSD.org/cgi/query-pr.cgi?pr=%s";
75: #
76: #$prkeyword = "PR";
3.1 knu 77:
78: ##############
3.15 knu 79: # Manual gateway
3.8 knu 80: ##############
3.26 knu 81: $mancgi =
82: "http://www.FreeBSD.org/cgi/man.cgi?apropos=0&sektion=%s&query=%s&manpath=FreeBSD+5.0-current&format=html";
3.1 knu 83:
84: ##############
85: # Defaults for UserSettings
86: ##############
87: %DEFAULTVALUE = (
3.26 knu 88:
89: # sortby: File sort order
90: # file Sort by filename
91: # rev Sort by revision number
92: # date Sort by commit date
93: # author Sort by author
94: # log Sort by log message
95:
96: "sortby" => "file",
97:
98: # hideattic: Hide or show files in Attic
99: # 1 Hide files in Attic
100: # 0 Show files in Attic
101:
102: "hideattic" => "1",
103:
104: # logsort: Sort order for CVS logs
105: # date Sort revisions by date
106: # rev Sort revision by revision number
107: # cvs Don't sort them. Same order as CVS/RCS shows them.
108:
109: "logsort" => "date",
110:
111: # f: Default diff format
112: # h Human readable
113: # u Unified diff
114: # c Context diff
115: # s Side by side
116: "f" => "u",
117:
118: # hidecvsroot: Don't show the CVSROOT directory
119: # 1 Hide CVSROOT directory
120: # 0 Show CVSROOT directory
121: "hidecvsroot" => "0",
122:
123: # hidenonreadable: Don't show entries which cannot be read
124: # 1 Hide non-readable entries
125: # 0 Show non-readable entries
126: "hidenonreadable" => "1",
3.1 knu 127: );
128:
129: ##############
130: # some layout stuff
131: ##############
132:
3.9 knu 133: # The body-tag for directory views and logs
3.1 knu 134: $body_tag = '<body text="#000000" bgcolor="#ffffff">';
135:
3.9 knu 136: # The body-tag for diffs and annotations
137: $body_tag_for_src = '<body text="#000000" bgcolor="#eeeeee">';
138:
3.1 knu 139: # Wanna have a logo on the page ?
140: $logo = '<img src="/icons/apache_pb.gif">';
141:
142: # The title of the Page on startup
143: $defaulttitle = "CVS Repository";
144:
145: # The address is shown on the footer
3.2 knu 146: $address = "<font size=-1>CVSweb by <knu\@FreeBSD.org></font>";
3.1 knu 147:
148: # color of navigation Header for
149: # diffs and annotations
150: $navigationHeaderColor = '#9999ee';
151:
152: $long_intro = <<EOT;
153: <p>
154: This is a WWW interface for CVS Repositories.
155: You can browse the file hierarchy by picking directories
156: (which have slashes after them, <i>e.g.</i>, <b>src/</b>).
157: If you pick a file, you will see the revision history
158: for that file.
159: Selecting a revision number will download that revision of
160: the file. There is a link at each revision to display
161: diffs between that revision and the previous one, and
162: a form at the bottom of the page that allows you to
163: display diffs between arbitrary revisions.
164: </p>
165: <p>
3.22 knu 166: This script has been written by Bill Fenner <<a
167: href="mailto:fenner\@FreeBSD.org">fenner\@FreeBSD.org</a>> and
168: improved by Henner Zeller <<a
169: href="mailto:zeller\@think.de">zeller\@think.de</a>>, Henrik
170: Nordström <<a
171: href="mailto:hno\@hem.passagen.se">hno\@hem.passagen.se</a>>, and
172: Ken Coar <<a
173: href="mailto:Ken.Coar\@Golux.Com">Ken.Coar\@Golux.Com</a>>, then
174: Akinori MUSHA <<a
175: href="mailto:knu\@FreeBSD.org">knu\@FreeBSD.org</a>> brought it
176: back to FreeBSD community and made further improvements; it is covered
177: by the <a
178: href="http://www.opensource.org/licenses/bsd-license.html">BSD-Licence</a>.
3.1 knu 179: </p>
180: <p>
181: If you would like to use this CGI script on your own web server and
3.23 knu 182: CVS tree, download the latest version <a
3.24 knu 183: href="http://www.idaemons.org/~knu/cvsweb/">here</a>, and also check
184: out Zeller's <a
3.22 knu 185: href="http://linux.fh-heilbronn.de/~zeller/cgi/cvsweb.cgi" >CVSweb
186: distribution site</a>. Bill's original script can be found <a
187: href="http://www.FreeBSD.org/~fenner/cvsweb/">here</a>.
3.1 knu 188: </p>
189: <p>
190: Please send any suggestions, comments, etc. to
3.5 knu 191: <a href="mailto:fenner\@FreeBSD.org">Bill Fenner</a> or, regarding the
3.1 knu 192: modifications, to
193: <a href="mailto:knu\@FreeBSD.org">Akinori MUSHA</a>,
194: <a href="mailto:zeller\@think.de">Henner Zeller</a>,
195: <a href="mailto:hno\@hem.passagen.se">Henrik Nordström</a>, or
196: <a href="mailto:Ken.Coar\@Golux.Com">Ken Coar</a>.
197: </p>
198: EOT
199:
200: $short_instruction = <<EOT;
201: <p>
202: Click on a directory to enter that directory. Click on a file to display
203: its revision history and to get a chance to display diffs between revisions.
204: </p>
205: EOT
206:
207: # used icons; if icon-url is empty, the text representation is used; if
208: # you do not want to have an ugly tooltip for the icon, remove the
209: # text-representation.
210: # The width and height of the icon allow the browser to correcly display
211: # the table while still loading the icons.
212: # These default icons are coming with apache.
213: # If these icons are too large, check out the miniicons in the
214: # icons/ directory; they have a width/height of 16/16
3.15 knu 215: my $iconsdir = "/icons";
3.26 knu 216:
3.15 knu 217: # format: TEXT ICON-URL width height
3.26 knu 218: %ICONS = (
219: back => [("[BACK]", "$iconsdir/back.gif", 20, 22)],
220: dir => [("[DIR]", "$iconsdir/dir.gif", 20, 22)],
221: file => [("[TXT]", "$iconsdir/text.gif", 20, 22)],
222: );
3.15 knu 223: undef $iconsdir;
3.1 knu 224:
225: # the length to which the last logentry should
226: # be truncated when shown in the directory view
227: $shortLogLen = 80;
228:
229: # Show author of last change
230: $show_author = 1;
231:
232: ##############
233: # table view for directories
234: ##############
235:
236: # Show directory as table
237: # this is much more readable but has one
238: # drawback: the whole table has to be loaded
239: # before common browsers display it which may
240: # be annoying if you have a slow link - and a
241: # large directory ..
242: $dirtable = 1;
243:
244: # show different colors for even/odd rows
245: @tabcolors = ('#ffffff', '#ffffff');
246: $tablepadding = 2;
247:
248: # Color of Header
249: $columnHeaderColorDefault = '#ffffcc';
250: $columnHeaderColorSorted = '#ffcc66';
251:
252: #
253: # If you want to have colored borders
254: # around each row, uncomment this
255: $tableBorderColor = '#cccccc';
256:
257: #
258: # Modules in the repository that should not be displayed, either by default
259: # nor by explicit path specification.
260: #
3.27 ! knu 261: @HideModules = (
! 262: # "^my/secret/module",
! 263: );
! 264:
! 265: #
! 266: # Files matching these pathnames shouldn't be checked out with cvsweb,
! 267: # since they may contain sensitive information. Simple file name based
! 268: # filter. Often, the CVSROOT/passwd is exposed and some people tend
! 269: # to check in their .cvspass, though this is a bad idea. These files
! 270: # shouldn't be readable by default. Thanks to Damian Gryski to point
! 271: # this out.
! 272: @ForbiddenFiles = (
! 273: "^CVSROOT/passwd\$", # CVSROOT/passwd should not be cvs add'ed, though
! 274: "/\\.cvspass\$", # Ditto. Just in case.
! 275: );
3.1 knu 276:
277: #
278: # Use CVSROOT/CVSROOT/descriptions for describing the directories/modules
279: # See INSTALL section 8
280: #
281: $use_descriptions = 0;
282:
283: ##############
284: # Human Readable Diff
285: ##############
286:
287: # (c) 1998 H. Zeller <zeller@think.de>
288: #
289: # Generates two columns of color encoded
290: # diff; much like xdiff or emacs-ediff mode.
291: #
292: # The diff-stuff is a piece of code I once made for
293: # cvs2html which is under GPL,
294: # see http://www.sslug.dk/cvs2html
295: # (c) 1997/98 Peter Toft <pto@sslug.imm.dtu.dk>
296: #
297: # some parameters to screw:
298: ##
299:
300: # make lines breakable so that the columns do not
301: # exceed the width of the browser
302: $hr_breakable = 1;
303:
3.4 knu 304: # give out function names in diffs
3.1 knu 305: # this just makes sense if we have C-files, otherwise
306: # diff's heuristic doesn't work well ..
307: # ( '-p' option to diff)
3.4 knu 308: $showfunc = 1;
3.1 knu 309:
310: # For each pair of regexps, files that match the first regexp will be diff'ed
311: # with an '-F' option with the second regexp.
3.4 knu 312: %funcline_regexp = (
3.26 knu 313: "\\.(4th|fr)\$" => "\\(^\\|[ \t]\\): ",
314: "\\.rb\$" => "^[\t ]*\\(class\\|module\\|def\\) ",
315: );
3.1 knu 316:
317: # ignore whitespaces for human readable diffs
318: # (indendation and stuff ..)
319: # ( '-w' option to diff)
3.7 knu 320: $hr_ignwhite = 0;
3.1 knu 321:
322: # ignore diffs which are caused by
323: # keyword-substitution like $Id - Stuff
324: # ( '-kk' option to rcsdiff)
325: $hr_ignkeysubst = 1;
326:
327: # Colors and font to show the diff type of code changes
3.26 knu 328: $diffcolorHeading = '#99cccc'; # color of 'Line'-head of each diffed file
329: $diffcolorEmpty = '#cccccc'; # color of 'empty' lines
330: $diffcolorRemove = '#ff9999'; # Removed line(s) (left) ( - )
331: $diffcolorChange = '#99ff99'; # Changed line(s) ( both )
332: $diffcolorAdd = '#ccccff'; # Added line(s) ( - ) (right)
333: $diffcolorDarkChange = '#99cc99'; # lines, which are empty in change
334: $difffontface = "Helvetica,Arial";
335: $difffontsize = "-1";
3.1 knu 336:
337: # the width of the textinput of the
338: # request-diff-form
339: $inputTextSize = 12;
340:
341: ##############
342: # Mime Types
343: ##############
344:
345: # mapping to mimetypes to help
346: # cvsweb to guess the correct mime-type on
347: # checkout; you can use the mime.types from
348: # apache here:
349: $mime_types = '/usr/local/etc/apache/mime.types';
350:
351: # quick mime-type lookup; maps file-suffices to
352: # mime-types for displaying checkouts in the browser.
353: # Further MimeTypes will be found in the
354: # file $mime_types (apache style mime.types - file)
355: # - add common mappings here for faster lookup
356: %MTYPES = (
3.26 knu 357: "html" => "text/html",
358: "shtml" => "text/html",
359: "gif" => "image/gif",
360: "jpeg" => "image/jpeg",
361: "jpg" => "image/jpeg",
362: "png" => "image/png",
363: "xpm" => "image/xpm",
364: "*" => "text/plain",
365: );
3.11 knu 366:
367: # Charset for HTML output
3.13 knu 368: $charset = '';
3.26 knu 369:
3.13 knu 370: # e.g.
371: #$charset = $where =~ m,/ru[/_-], ? 'koi8-r'
372: # : $where =~ m,/zh[/_-], ? 'big5'
373: # : $where =~ m,/ja[/_-], ? 'x-euc-jp'
374: # : $where =~ m,/ko[/_-], ? 'x-euc-kr'
375: # : 'iso-8859-1';
3.1 knu 376:
377: ##############
378: # Misc
379: ##############
380: # allow annotation of files
381: # this requires rw-access to the
3.12 knu 382: # CVSROOT/history file (if you have one)
383: # and rw-access to the subdirectory to
384: # place the lock so you maybe don't want it
3.1 knu 385: $allow_annotate = 1;
386:
387: # allow pretty-printed version of files
388: $allow_markup = 1;
389:
390: # allow compression with gzip
391: # of output if the Browser accepts
392: # it (HTTP_ACCEPT_ENCODING=gzip)
393: # [make sure to have gzip in the path]
3.16 knu 394: $allow_compress = 0;
3.1 knu 395:
396: # Make use of javascript functions.
397: # This way you can select one of your CVSroot
398: # without pressing 'Go' (.. if you do have more
399: # than one CVSROOT defined)
400: $use_java_script = 1;
401:
402: # open Download-Links in another window
403: $open_extern_window = 1;
404:
405: # The size of this extern window; this size option
406: # needs use_java_script to be defined
407: # just comment them if you don't want to have a fixed
408: # size
409: #$extern_window_width = 600;
410: #$extern_window_height = 440;
411:
412: # Edit Options
413: # Enable form to edit your options (hideattic,sortbydate)
414: # this isn't necessary if you've $dirtable defined 'cause
415: # this allows editing of all your options more intuitive
416: $edit_option_form = (not $dirtable);
417:
418: # If you have files which automatically refers to other files
419: # (such as HTML) then this allows you to browse the checked
420: # out files as if outside CVS.
421: $checkout_magic = 1;
422:
423: # Show last changelog message for sub directories
424: # The current implementation makes many assumptions and may show the
425: # incorrect file at some times. The main assumption is that the last
426: # modified file has the newest filedate. But some CVS operations
427: # touches the file without even when a new version is't checked in,
428: # and TAG based browsing essientially puts this out of order, unless
429: # the last checkin was on the same tag as you are viewing.
430: # Enable this if you like the feature, but don't rely on correct results.
431: $show_subdir_lastmod = 0;
432:
433: # Background color of logentry in markup
434: $markupLogColor = "#ffffff";
435:
436: # Show CVS log when viewing file contents
437: $show_log_in_markup = 1;
438:
3.13 knu 439: # Preformat when viewing file contents. This should be turned off
440: # when you have files in the repository that are in a multibyte
441: # encoding which uses HTML special characters ([<>&"]) as part of a
442: # multi-byte character. (such as iso-2022-jp, ShiftJIS, etc.)
443: # Otherwise those files will get screwed up in markup.
444: $preformat_in_markup = '';
445:
3.1 knu 446: # Tabstop used to expand tabs in colored diffs. If undefined then
447: # tabs are always expanded to 8 spaces.
448: $tabstop = 8;
449:
450: # if you wish to display absolute times in your local timezone,
451: # then define mytz and fill in the strings for your standard and
452: # daylight time. Note that you must also make sure the system
453: # timezone is correctly set.
454: # @mytz=("EST", "EDT");
455:
456: # cvsweb is friendly to caches by indicating a suitable
457: # last-modified timestamp. Doing this uses slightly more
458: # CPU so you might want to disable it if you have a slow
459: # server
460: $use_moddate = 1;
461:
3.12 knu 462: # Allows downloading a tarball of the current directory if set.
463: # Bear in mind that this allows downloading a tarball of your entire
464: # repository, which can take a lot of time and disk space to create!
465: # If you enable this, you may need to make sure that cvsweb can write to
466: # CVSROOT/val-tags, due to a bug in cvs.
467: $allow_tar = '';
3.13 knu 468:
469: # Options to pass to tar(1).
3.15 knu 470: @tar_options = qw();
3.26 knu 471:
3.13 knu 472: # e.g. @tar_options = qw(--ignore-failed-read);
473: # GNU tar has some useful options against unexpected errors.
474:
3.19 knu 475: # Options to pass to gzip(1) when compressing a tarball to download.
476: @gzip_options = qw();
3.26 knu 477:
3.19 knu 478: # e.g. @gzip_options = qw(-3);
3.25 knu 479: # Try lower compression level than 6 (default) if you want faster
480: # compression, or higher, for better compression.
481:
482: # Options to pass to zip(1) when compressing a zip archive to download.
483: @zip_options = qw();
3.26 knu 484:
3.25 knu 485: # e.g. @zip_options = qw(-3);
3.19 knu 486: # Try lower compression level than 6 (default) if you want faster
3.21 knu 487: # compression, or higher, for better compression.
3.19 knu 488:
3.13 knu 489: # Options to pass to cvs(1).
490: @cvs_options = qw(-l);
3.19 knu 491:
492: push @cvs_options, '-R' if ($uname eq 'FreeBSD' || $uname eq 'OpenBSD');
3.26 knu 493:
3.19 knu 494: # Only FreeBSD's and OpenBSD's cvs(1) supports -R (read only access
495: # mode) option, which considerably speeds up checkouts over NFS.
3.12 knu 496:
497: 1;
3.26 knu 498:
3.1 knu 499: #EOF
CVSweb