@@ -28,8 +28,7 @@ scripts).
28
28
Build time configuration
29
29
------------------------
30
30
31
- See also "How to configure gitweb for your local system" in README
32
- file for gitweb (in gitweb/README).
31
+ See also "How to configure gitweb for your local system" section below.
33
32
34
33
- There are many configuration variables which affect building of
35
34
gitweb.cgi; see "default configuration for gitweb" section in main
@@ -73,6 +72,118 @@ file for gitweb (in gitweb/README).
73
72
substitute gitweb.min.js and gitweb.min.css for all uses of gitweb.js and
74
73
gitweb.css in the help files.
75
74
75
+
76
+ How to configure gitweb for your local system
77
+ ---------------------------------------------
78
+
79
+ You can specify the following configuration variables when building GIT:
80
+
81
+ * GIT_BINDIR
82
+ Points where to find the git executable. You should set it up to
83
+ the place where the git binary was installed (usually /usr/bin) if you
84
+ don't install git from sources together with gitweb. [Default: $(bindir)]
85
+ * GITWEB_SITENAME
86
+ Shown in the title of all generated pages, defaults to the server name
87
+ (SERVER_NAME CGI environment variable) if not set. [No default]
88
+ * GITWEB_PROJECTROOT
89
+ The root directory for all projects shown by gitweb. Must be set
90
+ correctly for gitweb to find repositories to display. See also
91
+ "Gitweb repositories" in the INSTALL file for gitweb. [Default: /pub/git]
92
+ * GITWEB_PROJECT_MAXDEPTH
93
+ The filesystem traversing limit for getting the project list; the number
94
+ is taken as depth relative to the projectroot. It is used when
95
+ GITWEB_LIST is a directory (or is not set; then project root is used).
96
+ This is meant to speed up project listing on large work trees by limiting
97
+ search depth. [Default: 2007]
98
+ * GITWEB_LIST
99
+ Points to a directory to scan for projects (defaults to project root
100
+ if not set / if empty) or to a file with explicit listing of projects
101
+ (together with projects' ownership). See "Generating projects list
102
+ using gitweb" in INSTALL file for gitweb to find out how to generate
103
+ such file from scan of a directory. [No default, which means use root
104
+ directory for projects]
105
+ * GITWEB_EXPORT_OK
106
+ Show repository only if this file exists (in repository). Only
107
+ effective if this variable evaluates to true. [No default / Not set]
108
+ * GITWEB_STRICT_EXPORT
109
+ Only allow viewing of repositories also shown on the overview page.
110
+ This for example makes GITWEB_EXPORT_OK to decide if repository is
111
+ available and not only if it is shown. If GITWEB_LIST points to
112
+ file with list of project, only those repositories listed would be
113
+ available for gitweb. [No default]
114
+ * GITWEB_HOMETEXT
115
+ Points to an .html file which is included on the gitweb project
116
+ overview page ('projects_list' view), if it exists. Relative to
117
+ gitweb.cgi script. [Default: indextext.html]
118
+ * GITWEB_SITE_HEADER
119
+ Filename of html text to include at top of each page. Relative to
120
+ gitweb.cgi script. [No default]
121
+ * GITWEB_SITE_FOOTER
122
+ Filename of html text to include at bottom of each page. Relative to
123
+ gitweb.cgi script. [No default]
124
+ * GITWEB_HOME_LINK_STR
125
+ String of the home link on top of all pages, leading to $home_link
126
+ (usually main gitweb page, which means projects list). Used as first
127
+ part of gitweb view "breadcrumb trail": <home> / <project> / <view>.
128
+ [Default: projects]
129
+ * GITWEB_SITENAME
130
+ Name of your site or organization to appear in page titles. Set it
131
+ to something descriptive for clearer bookmarks etc. If not set
132
+ (if empty) gitweb uses "$SERVER_NAME Git", or "Untitled Git" if
133
+ SERVER_NAME CGI environment variable is not set (e.g. if running
134
+ gitweb as standalone script). [No default]
135
+ * GITWEB_BASE_URL
136
+ Git base URLs used for URL to where fetch project from, i.e. full
137
+ URL is "$git_base_url/$project". Shown on projects summary page.
138
+ Repository URL for project can be also configured per repository; this
139
+ takes precedence over URLs composed from base URL and a project name.
140
+ Note that you can setup multiple base URLs (for example one for
141
+ git:// protocol access, another for http:// access) from the gitweb
142
+ config file. [No default]
143
+ * GITWEB_CSS
144
+ Points to the location where you put gitweb.css on your web server
145
+ (or to be more generic, the URI of gitweb stylesheet). Relative to the
146
+ base URI of gitweb. Note that you can setup multiple stylesheets from
147
+ the gitweb config file. [Default: static/gitweb.css (or
148
+ static/gitweb.min.css if the CSSMIN variable is defined / CSS minifier
149
+ is used)]
150
+ * GITWEB_LOGO
151
+ Points to the location where you put git-logo.png on your web server
152
+ (or to be more generic URI of logo, 72x27 size, displayed in top right
153
+ corner of each gitweb page, and used as logo for Atom feed). Relative
154
+ to base URI of gitweb. [Default: static/git-logo.png]
155
+ * GITWEB_FAVICON
156
+ Points to the location where you put git-favicon.png on your web server
157
+ (or to be more generic URI of favicon, assumed to be image/png type;
158
+ web browsers that support favicons (website icons) may display them
159
+ in the browser's URL bar and next to site name in bookmarks). Relative
160
+ to base URI of gitweb. [Default: static/git-favicon.png]
161
+ * GITWEB_JS
162
+ Points to the location where you put gitweb.js on your web server
163
+ (or to be more generic URI of JavaScript code used by gitweb).
164
+ Relative to base URI of gitweb. [Default: static/gitweb.js (or
165
+ static/gitweb.min.js if JSMIN build variable is defined / JavaScript
166
+ minifier is used)]
167
+ * GITWEB_CONFIG
168
+ This Perl file will be loaded using 'do' and can be used to override any
169
+ of the options above as well as some other options -- see the "Runtime
170
+ gitweb configuration" section below, and top of 'gitweb.cgi' for their
171
+ full list and description. If the environment variable GITWEB_CONFIG
172
+ is set when gitweb.cgi is executed, then the file specified in the
173
+ environment variable will be loaded instead of the file specified
174
+ when gitweb.cgi was created. [Default: gitweb_config.perl]
175
+ * GITWEB_CONFIG_SYSTEM
176
+ This Perl file will be loaded using 'do' as a fallback if GITWEB_CONFIG
177
+ does not exist. If the environment variable GITWEB_CONFIG_SYSTEM is set
178
+ when gitweb.cgi is executed, then the file specified in the environment
179
+ variable will be loaded instead of the file specified when gitweb.cgi was
180
+ created. [Default: /etc/gitweb.conf]
181
+ * HIGHLIGHT_BIN
182
+ Path to the highlight executable to use (must be the one from
183
+ http://www.andre-simon.de due to assumptions about parameters and output).
184
+ Useful if highlight is not installed on your webserver's PATH.
185
+ [Default: highlight]
186
+
76
187
Build example
77
188
~~~~~~~~~~~~~
78
189
0 commit comments