From: Matthias Lederhofer <matled@gmx.net>
To: Jeff King <peff@peff.net>
Cc: git@vger.kernel.org
Subject: Re: [PATCH] gitweb.cgi: Customization
Date: Wed, 2 Aug 2006 19:13:11 +0200 [thread overview]
Message-ID: <E1G8KHP-0004j5-4P@moooo.ath.cx> (raw)
In-Reply-To: <20060802165333.GA22726@coredump.intra.peff.net>
Jeff King <peff@peff.net> wrote:
> On Wed, Aug 02, 2006 at 11:23:22AM -0500, Jon Loeliger wrote:
> Why don't we have sensible compile-time defaults that can be overridden
> by a run-time config file like every other sane program? For those who
> are opposed to the run-time config, they can simply not have a config
> file.
>
> See the (completely untested) patch below. Obviously the config file
> name has to be set at build time. However, since it is interpolated by
> perl, you can do clever things like:
> /etc/gitweb/$ENV{MY_VIRTUAL_HOST}.pl
I like this (it is quite similar to my suggestions :)).
> --- a/gitweb/gitweb.perl
> +++ b/gitweb/gitweb.perl
> @@ -66,6 +66,9 @@ # file to use for guessing MIME types be
> # (relative to the current git repository)
> our $mimetypes_file = undef;
>
> +our $GITWEB_CONFIG = "@@GITWEB_CONFIG@@";
> +require $GITWEB_CONFIG if -e $GITWEB_CONFIG;
> +
> # input validation and dispatch
> our $action = $cgi->param('a');
> if (defined $action) {
The only other thing to change is to move the mkdir($git_temp) and
qx($GIT --version) below this line.
next prev parent reply other threads:[~2006-08-02 17:13 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-08-01 21:19 [PATCH] gitweb.cgi: Customization Luben Tuikov
2006-08-01 22:15 ` Junio C Hamano
2006-08-01 22:53 ` Luben Tuikov
2006-08-01 23:54 ` Junio C Hamano
2006-08-02 2:01 ` Luben Tuikov
2006-08-02 2:13 ` Martin Langhoff
2006-08-02 7:45 ` Junio C Hamano
2006-08-02 7:59 ` Martin Langhoff
2006-08-02 15:53 ` Matthias Lederhofer
2006-08-03 6:58 ` Martin Waitz
2006-08-03 16:24 ` Jeff King
2006-08-02 7:09 ` Matthias Lederhofer
2006-08-02 8:54 ` Matthias Lederhofer
2006-08-02 9:31 ` Martin Langhoff
2006-08-02 12:55 ` Matthias Lederhofer
2006-08-02 16:23 ` Jon Loeliger
2006-08-02 16:53 ` Jeff King
2006-08-02 17:13 ` Matthias Lederhofer [this message]
2006-08-02 17:34 ` Jakub Narebski
2006-08-02 17:43 ` Junio C Hamano
2006-08-02 20:30 ` Luben Tuikov
2006-08-02 19:40 ` Matthias Lederhofer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=E1G8KHP-0004j5-4P@moooo.ath.cx \
--to=matled@gmx.net \
--cc=git@vger.kernel.org \
--cc=peff@peff.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).