@matheusbsbs / matheus-bagliano / commits / d8f1c5c2f3
Fork 0

rename "branches" to "heads"

Signed-off-by: Kay Sievers <kay.sievers@suse.de>

Kay Sievers committed Oct 4, 2005 at 01:12 UTC d8f1c5c2f37433ef9ce56847d81314ea2798ac3c
1 file changed +9 -9
gitweb.cgi
+9 -9
@@ -5,7 +5,7 @@
5 # (C) 2005, Kay Sievers <kay.sievers@vrfy.org>
6 # (C) 2005, Christian Gierke <ch@gierke.de>
7 #
8 -# This program is licensed under the GPL v2, or a later version
8 +# This program is licensed under the GPLv2
9
10 use strict;
11 use warnings;
@@ -152,8 +152,8 @@ sub validate_input {
152 if (!defined $action || $action eq "summary") {
153 git_summary();
154 exit;
155 -} elsif ($action eq "branches") {
156 - git_branches();
155 +} elsif ($action eq "heads") {
156 + git_heads();
157 exit;
158 } elsif ($action eq "tags") {
159 git_tags();
@@ -1067,15 +1067,15 @@ sub git_summary {
1067 print "</table\n>";
1068 }
1069
1070 - my $branchlist = git_read_refs("refs/heads");
1071 - if (defined @$branchlist) {
1070 + my $headlist = git_read_refs("refs/heads");
1071 + if (defined @$headlist) {
1072 print "<div>\n" .
1073 - $cgi->a({-href => "$my_uri?p=$project;a=branches", -class => "title"}, "branches") .
1073 + $cgi->a({-href => "$my_uri?p=$project;a=heads", -class => "title"}, "heads") .
1074 "</div>\n";
1075 my $i = 16;
1076 print "<table cellspacing=\"0\">\n";
1077 my $alternate = 0;
1078 - foreach my $entry (@$branchlist) {
1078 + foreach my $entry (@$headlist) {
1079 my %tag = %$entry;
1080 if ($alternate) {
1081 print "<tr class=\"dark\">\n";
@@ -1095,7 +1095,7 @@ sub git_summary {
1095 "</td>\n" .
1096 "</tr>";
1097 } else {
1098 - print "<td>" . $cgi->a({-href => "$my_uri?p=$project;a=branches"}, "...") . "</td>\n" .
1098 + print "<td>" . $cgi->a({-href => "$my_uri?p=$project;a=heads"}, "...") . "</td>\n" .
1099 "</tr>";
1100 last;
1101 }
@@ -1203,7 +1203,7 @@ sub git_tags {
1203 git_footer_html();
1204 }
1205
1206 -sub git_branches {
1206 +sub git_heads {
1207 my $head = git_read_hash("$project/HEAD");
1208 git_header_html();
1209 print "<div class=\"page_nav\">\n" .