summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@linux.intel.com>2015-06-11 16:04:41 -0700
committerH. Peter Anvin <hpa@linux.intel.com>2015-06-11 16:04:41 -0700
commitc2e52b428ed39634aa9dc55f13e91e22d6f4d36c (patch)
tree210636c59c8253175243d013adae33cce1918644
parent5f6f8be43c172e74f0dd4747f264f301336c83c5 (diff)
downloadgitweb2cgit-c2e52b428ed39634aa9dc55f13e91e22d6f4d36c.tar.gz
gitweb2cgit-c2e52b428ed39634aa9dc55f13e91e22d6f4d36c.tar.xz
gitweb2cgit-c2e52b428ed39634aa9dc55f13e91e22d6f4d36c.zip
tags: remove refs/tags/ prefix from id=
Apparently cgit doesn't like refs/tags/ in the /tag/ command
-rwxr-xr-xgitweb2cgit.cgi5
1 files changed, 5 insertions, 0 deletions
diff --git a/gitweb2cgit.cgi b/gitweb2cgit.cgi
index fbf63e4..7eb8a0b 100755
--- a/gitweb2cgit.cgi
+++ b/gitweb2cgit.cgi
@@ -126,6 +126,11 @@ my $s = $sorts{$parm{'o'}};
$parm{'s'} = $s if (defined($s));
delete $parm{'o'};
+# Tags handling
+if ($a eq 'tag') {
+ $id =~ s:^refs/tags/::; # Drop leading refs/tags
+}
+
# Snapshot handling
my %snapform = (
'tgz' => '.tar.gz',