From 3286081786b404db5072059d3dbd4bdd660b9f96 Mon Sep 17 00:00:00 2001 From: "martin f. krafft" Date: Fri, 12 Mar 2010 12:31:11 +0100 Subject: [PATCH] add madduck alias URL shortcut Signed-off-by: martin f. krafft --- gitweb.conf | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/gitweb.conf b/gitweb.conf index 7721330..bf549aa 100644 --- a/gitweb.conf +++ b/gitweb.conf @@ -1,12 +1,13 @@ -$subdir = "madduck/pub"; +$vhostdir = "madduck"; +$pubdir = "pub"; $confroot = "/srv/git/gitweb/git.madduck.net"; -$projectroot = "/srv/git/repos/$subdir"; +$projectroot = "/srv/git/repos/$vhostdir/$pubdir"; $git_temp = "/tmp"; $site_header = "$confroot/header.html"; $site_footer = "$confroot/footer.html"; $projects_list = $projectroot; $default_projects_order = "project"; -@git_base_url_list=("git://git.madduck.net/$subdir", "ssh://git@git.madduck.net/$subdir"); +@git_base_url_list=("git://git.madduck.net/$vhostdir/$pubdir", "ssh://git@git.madduck.net/$vhostdir/$pubdir", "madduck:$pubdir"); $logo = '/git-logo.png'; $favicon = '/git-favicon.png'; push @stylesheets, '/gitweb.css'; @@ -24,7 +25,7 @@ die "parse $gl_conf_compiled failed: " . ($! or $@) unless do $gl_conf_compiled; $export_auth_hook = sub { # open FILE, ">>/tmp/gitweb.auth" or die $!; - my $reponame = "$subdir/" . shift; + my $reponame = "$vhostdir/$pubdir/" . shift; # gitweb passes us the full repo path; so we strip the beginning... $reponame =~ s/\Q$projectroot\E\/?//; # ...and the end, to get the repo name as it is specified in gitolite conf -- 2.39.2