Girocco::Config: Introduce $title configuration variable
[girocco.git] / gitweb_config.perl
blobd6a9a438514b0b2606cd48f22248d488d2dbd738
1 # Pull Girocco config
2 use lib ".";
3 use Girocco::Config;
5 # Base web paths
6 our $_web_path = "/";
7 our $_cgi_web_path = "/";
8 our $my_uri = $Girocco::Config::gitweburl;
10 ## core git executable to use
11 ## this can just be "git" if your webserver has a sensible PATH
12 our $GIT = $Girocco::Config::git_bin";
14 ## absolute fs-path which will be prepended to the project path
15 our $projectroot = $Girocco::Config::reporoot;
17 ## fs traversing limit for getting project list
18 ## the number is relative to the projectroot
19 #our $project_maxdepth = "2007";
21 ## target of the home link on top of all pages
22 our $home_link = "$_cgi_web_path";
24 ## string of the home link on top of all pages
25 our $home_link_str = $Girocco::Config::name;
27 ## name of your site or organization to appear in page titles
28 ## replace this with something more descriptive for clearer bookmarks
29 our $site_name = $Girocco::Config::title;
30 ## filename of html text to include at top of each page
31 #our $site_header = "";
32 ## html text to include at home page
33 #our $home_text = "indextext.html";
34 ## filename of html text to include at bottom of each page
35 #our $site_footer = "";
37 ## URI of stylesheets
38 our @stylesheets = ("$_web_path/gitweb.css");
39 ## URI of a single stylesheet, which can be overridden in GITWEB_CONFIG.
40 #our $stylesheet = undef;
41 ## URI of GIT logo (72x27 size)
42 our $logo = "$_web_path/git-logo.png";
43 ## URI of GIT favicon, assumed to be image/png type
44 our $favicon = "$_web_path/git-favicon.png";
45 ## URI of blame.js
46 our $blamejs = "$_web_path/blame.js";
47 ## URI of gitweb.js
48 our $gitwebjs = "$_web_path/gitweb.js";
50 ## URI and label (title) of GIT logo link
51 ##our $logo_url = "http://www.kernel.org/pub/software/scm/git/docs/";
52 ##our $logo_label = "git documentation";
53 #our $logo_url = "http://git.or.cz/";
54 #our $logo_label = "git homepage";
56 ## source of projects list
57 #our $projects_list = "";
59 ## the width (in characters) of the projects list "Description" column
60 #our $projects_list_description_width = 25;
62 ## default order of projects list
63 ## valid values are none, project, descr, owner, and age
64 #our $default_projects_order = "project";
66 ## show repository only if this file exists
67 ## (only effective if this variable evaluates to true)
68 #our $export_ok = "";
70 ## only allow viewing of repositories also shown on the overview page
71 #our $strict_export = "";
73 ## list of git base URLs used for URL to where fetch project from,
74 ## i.e. full URL is "$git_base_url/$project"
75 our @git_base_url_list = ();
76 $Girocco::Config::gitpullurl and push @git_base_url_list, $Girocco::Config::gitpullurl;
77 $Girocco::Config::httppullurl and push @git_base_url_list, $Girocco::Config::httppullurl;
79 ## default blob_plain mimetype and default charset for text/plain blob
80 #our $default_blob_plain_mimetype = 'text/plain';
81 #our $default_text_plain_charset = undef;
83 ## file to use for guessing MIME types before trying /etc/mime.types
84 ## (relative to the current git repository)
85 #our $mimetypes_file = undef;
87 ## assume this charset if line contains non-UTF-8 characters;
88 ## it should be valid encoding (see Encoding::Supported(3pm) for list),
89 ## for which encoding all byte sequences are valid, for example
90 ## 'iso-8859-1' aka 'latin1' (it is decoded without checking, so it
91 ## could be even 'utf-8' for the old behavior)
92 #our $fallback_encoding = 'latin1';
94 ## rename detection options for git-diff and git-diff-tree
95 ## - default is '-M', with the cost proportional to
96 ## (number of removed files) * (number of new files).
97 ## - more costly is '-C' (which implies '-M'), with the cost proportional to
98 ## (number of changed files + number of removed files) * (number of new files)
99 ## - even more costly is '-C', '--find-copies-harder' with cost
100 ## (number of files in the original tree) * (number of new files)
101 ## - one might want to include '-B' option, e.g. '-B', '-M'
102 #our @diff_opts = ('-M'); # taken from git_commit
104 ## projects list cache for busy sites with many projects;
105 ## if you set this to non-zero, it will be used as the cached
106 ## index lifetime in minutes
108 ## the cached list version is stored in $cache_dir/$cache_name and can
109 ## be tweaked by other scripts running with the same uid as gitweb -
110 ## use this ONLY at secure installations; only single gitweb project
111 ## root per system is supported, unless you tweak configuration!
112 #our $projlist_cache_lifetime = 0; # in minutes
113 our $projlist_cache_lifetime = 10;
114 ## FHS compliant $cache_dir would be "/var/cache/gitweb"
115 #our $cache_dir =
116 # (defined $ENV{'TMPDIR'} ? $ENV{'TMPDIR'} : '/tmp').'/gitweb';
117 #our $projlist_cache_name = 'gitweb.index.cache';
119 ## information about snapshot formats that gitweb is capable of serving
120 #our %known_snapshot_formats = (
121 # # name => {
122 # # 'display' => display name,
123 # # 'type' => mime type,
124 # # 'suffix' => filename suffix,
125 # # 'format' => --format for git-archive,
126 # # 'compressor' => [compressor command and arguments]
127 # # (array reference, optional)}
129 # 'tgz' => {
130 # 'display' => 'tar.gz',
131 # 'type' => 'application/x-gzip',
132 # 'suffix' => '.tar.gz',
133 # 'format' => 'tar',
134 # 'compressor' => ['gzip']},
136 # 'tbz2' => {
137 # 'display' => 'tar.bz2',
138 # 'type' => 'application/x-bzip2',
139 # 'suffix' => '.tar.bz2',
140 # 'format' => 'tar',
141 # 'compressor' => ['bzip2']},
143 # 'zip' => {
144 # 'display' => 'zip',
145 # 'type' => 'application/x-zip',
146 # 'suffix' => '.zip',
147 # 'format' => 'zip'},
150 ## Aliases so we understand old gitweb.snapshot values in repository
151 ## configuration.
152 #our %known_snapshot_format_aliases = (
153 # 'gzip' => 'tgz',
154 # 'bzip2' => 'tbz2',
156 # # backward compatibility: legacy gitweb config support
157 # 'x-gzip' => undef, 'gz' => undef,
158 # 'x-bzip2' => undef, 'bz2' => undef,
159 # 'x-zip' => undef, '' => undef,
162 ## You define site-wide feature defaults here; override them with
163 ## $GITWEB_CONFIG as necessary.
164 #our %feature = (
165 # # feature => {
166 # # 'sub' => feature-sub (subroutine),
167 # # 'override' => allow-override (boolean),
168 # # 'default' => [ default options...] (array reference)}
170 # # if feature is overridable (it means that allow-override has true value),
171 # # then feature-sub will be called with default options as parameters;
172 # # return value of feature-sub indicates if to enable specified feature
174 # # if there is no 'sub' key (no feature-sub), then feature cannot be
175 # # overriden
177 # # use gitweb_check_feature(<feature>) to check if <feature> is enabled
179 # # Enable the 'blame' blob view, showing the last commit that modified
180 # # each line in the file. This can be very CPU-intensive.
182 # # To enable system wide have in $GITWEB_CONFIG
183 # # $feature{'blame'}{'default'} = [1];
184 # # To have project specific config enable override in $GITWEB_CONFIG
185 # # $feature{'blame'}{'override'} = 1;
186 # # and in project config gitweb.blame = 0|1;
187 # 'blame' => {
188 # 'sub' => \&feature_blame,
189 # 'override' => 0,
190 # 'default' => [0]},
191 $feature{blame}{default}=[1];
193 # # Enable the 'snapshot' link, providing a compressed archive of any
194 # # tree. This can potentially generate high traffic if you have large
195 # # project.
197 # # Value is a list of formats defined in %known_snapshot_formats that
198 # # you wish to offer.
199 # # To disable system wide have in $GITWEB_CONFIG
200 # # $feature{'snapshot'}{'default'} = [];
201 # # To have project specific config enable override in $GITWEB_CONFIG
202 # # $feature{'snapshot'}{'override'} = 1;
203 # # and in project config, a comma-separated list of formats or "none"
204 # # to disable. Example: gitweb.snapshot = tbz2,zip;
205 # 'snapshot' => {
206 # 'sub' => \&feature_snapshot,
207 # 'override' => 0,
208 # 'default' => ['tgz']},
210 # # Enable text search, which will list the commits which match author,
211 # # committer or commit text to a given string. Enabled by default.
212 # # Project specific override is not supported.
213 # 'search' => {
214 # 'override' => 0,
215 # 'default' => [1]},
217 # # Enable grep search, which will list the files in currently selected
218 # # tree containing the given string. Enabled by default. This can be
219 # # potentially CPU-intensive, of course.
221 # # To enable system wide have in $GITWEB_CONFIG
222 # # $feature{'grep'}{'default'} = [1];
223 # # To have project specific config enable override in $GITWEB_CONFIG
224 # # $feature{'grep'}{'override'} = 1;
225 # # and in project config gitweb.grep = 0|1;
226 # 'grep' => {
227 # 'override' => 0,
228 # 'default' => [1]},
230 # # Enable the pickaxe search, which will list the commits that modified
231 # # a given string in a file. This can be practical and quite faster
232 # # alternative to 'blame', but still potentially CPU-intensive.
234 # # To enable system wide have in $GITWEB_CONFIG
235 # # $feature{'pickaxe'}{'default'} = [1];
236 # # To have project specific config enable override in $GITWEB_CONFIG
237 # # $feature{'pickaxe'}{'override'} = 1;
238 # # and in project config gitweb.pickaxe = 0|1;
239 # 'pickaxe' => {
240 # 'sub' => \&feature_pickaxe,
241 # 'override' => 0,
242 # 'default' => [1]},
244 # # Make gitweb use an alternative format of the URLs which can be
245 # # more readable and natural-looking: project name is embedded
246 # # directly in the path and the query string contains other
247 # # auxiliary information. All gitweb installations recognize
248 # # URL in either format; this configures in which formats gitweb
249 # # generates links.
251 # # To enable system wide have in $GITWEB_CONFIG
252 # # $feature{'pathinfo'}{'default'} = [1];
253 # # Project specific override is not supported.
255 # # Note that you will need to change the default location of CSS,
256 # # favicon, logo and possibly other files to an absolute URL. Also,
257 # # if gitweb.cgi serves as your indexfile, you will need to force
258 # # $my_uri to contain the script name in your $GITWEB_CONFIG.
259 # 'pathinfo' => {
260 # 'override' => 0,
261 # 'default' => [0]},
262 $feature{pathinfo}{default}=[1];
264 # # Make gitweb consider projects in project root subdirectories
265 # # to be forks of existing projects. Given project $projname.git,
266 # # projects matching $projname/*.git will not be shown in the main
267 # # projects list, instead a '+' mark will be added to $projname
268 # # there and a 'forks' view will be enabled for the project, listing
269 # # all the forks. If project list is taken from a file, forks have
270 # # to be listed after the main project.
272 # # To enable system wide have in $GITWEB_CONFIG
273 # # $feature{'forks'}{'default'} = [1];
274 # # Project specific override is not supported.
275 # 'forks' => {
276 # 'override' => 0,
277 # 'default' => [0]},
278 $feature{forks}{default}=[1];