shlib: Introduce progress() for progress messages, use in updatecheck.sh
[girocco/radio.git] / gitweb / gitweb_config.perl
blob4e9eecffeb1a27fb7cddf2662d2312fbf360b488
1 # Pull Girocco config
2 use lib ".";
3 use Girocco::Config;
5 # Base web path
6 our $my_uri = $Girocco::Config::gitweburl;
8 ## core git executable to use
9 ## this can just be "git" if your webserver has a sensible PATH
10 our $GIT = $Girocco::Config::git_bin;
12 ## absolute fs-path which will be prepended to the project path
13 our $projectroot = $Girocco::Config::reporoot;
15 ## fs traversing limit for getting project list
16 ## the number is relative to the projectroot
17 #our $project_maxdepth = "2007";
19 ## target of the home link on top of all pages
20 our $home_link = $Girocco::Config::gitweburl;
22 ## string of the home link on top of all pages
23 our $home_link_str = $Girocco::Config::name;
25 ## name of your site or organization to appear in page titles
26 ## replace this with something more descriptive for clearer bookmarks
27 our $site_name = $Girocco::Config::title;
28 ## filename of html text to include at top of each page
29 #our $site_header = "";
30 ## html text to include at home page
31 our $home_text = "$Girocco::Config::webroot/indextext.html";
32 ## filename of html text to include at bottom of each page
33 #our $site_footer = "";
35 ## URI of stylesheets
36 our @stylesheets = ("$Girocco::Config::gitwebfiles/gitweb.css");
37 ## URI of a single stylesheet, which can be overridden in GITWEB_CONFIG.
38 #our $stylesheet = undef;
39 ## URI of GIT logo (72x27 size)
40 our $logo = "$Girocco::Config::gitwebfiles/git-logo.png";
41 ## URI of GIT favicon, assumed to be image/png type
42 our $favicon = "$Girocco::Config::gitwebfiles/git-favicon.png";
43 ## URI of blame.js
44 our $blamejs = "$Girocco::Config::gitwebfiles/blame.js";
45 ## URI of gitweb.js
46 our $gitwebjs = "$Girocco::Config::gitwebfiles/gitweb.js";
48 ## URI and label (title) of GIT logo link
49 ##our $logo_url = "http://www.kernel.org/pub/software/scm/git/docs/";
50 ##our $logo_label = "git documentation";
51 #our $logo_url = "http://git.or.cz/";
52 #our $logo_label = "git homepage";
54 ## source of projects list
55 #our $projects_list = "";
57 ## the width (in characters) of the projects list "Description" column
58 #our $projects_list_description_width = 25;
60 ## default order of projects list
61 ## valid values are none, project, descr, owner, and age
62 #our $default_projects_order = "project";
64 ## show repository only if this file exists
65 ## (only effective if this variable evaluates to true)
66 #our $export_ok = "";
68 ## only allow viewing of repositories also shown on the overview page
69 #our $strict_export = "";
71 ## list of git base URLs used for URL to where fetch project from,
72 ## i.e. full URL is "$git_base_url/$project"
73 our @git_base_url_list = ();
74 $Girocco::Config::gitpullurl and push @git_base_url_list, $Girocco::Config::gitpullurl;
75 $Girocco::Config::httppullurl and push @git_base_url_list, $Girocco::Config::httppullurl;
77 our $git_push_url = $Girocco::Config::pushurl;
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];
280 # # Insert custom links to the action bar of all project pages.
281 # # This enables you mainly to link to third-party scripts integrating
282 # # into gitweb; e.g. git-browser for graphical history representation
283 # # or custom web-based repository administration interface.
285 # # The 'default' value consists of a list of triplets in the form
286 # # (label, link, position) where position is the label after which
287 # # to inster the link and link is a format string where %n expands
288 # # to the project name, %f to the project path within the filesystem,
289 # # %h to the current hash (h gitweb parameter) and %b to the current
290 # # hash base (hb gitweb parameter).
292 # # To enable system wide have in $GITWEB_CONFIG e.g.
293 # # $feature{'actions'}{'default'} = [('graphiclog',
294 # # '/git-browser/by-commit.html?r=%n', 'summary')];
295 # # Project specific override is not supported.
296 # 'actions' => {
297 # 'override' => 0,
298 # 'default' => []},
299 $feature{actions}{default}=[
300 ('graphiclog', "$Girocco::Config::gitwebfiles/git-browser/by-commit.html?r=%n", 'shortlog'),
301 ('edit', "$Girocco::Config::webadmurl/editproj.cgi?name=%n", 'tree'),
302 ('fork', "$Girocco::Config::webadmurl/regproj.cgi?fork=%n", 'edit')
305 # # Allow gitweb scan project content tags described in ctags/
306 # # of project repository, and display the popular Web 2.0-ish
307 # # "tag cloud" near the project list. Note that this is something
308 # # COMPLETELY different from the normal Git tags.
310 # # gitweb by itself can show existing tags, but it does not handle
311 # # tagging itself; you need an external application for that.
312 # # For an example script, check Girocco's cgi/tagproj.cgi.
314 # # To enable system wide have in $GITWEB_CONFIG
315 # # $feature{'ctags'}{'default'} = ['path_to_tag_script'];
316 # # Project specific override is not supported.
317 # 'ctags' => {
318 # 'override' => 0,
319 # 'default' => [0]},
320 $feature{ctags}{default}=["$Girocco::Config::webadmurl/tagproj.cgi"];