threads / patch / 5707

patchgitweb: Remove redundant "tree" link

Subject: [PATCH] gitweb: Remove redundant "tree" link

## tl;dr

2 messages between Sep 26, 2006 and Sep 26, 2006. Diffs are folded; open one to read it.

replies: 1people: 2as markdown or json

Luben Tuikov· Sep 26, 2006, 19:45 UTC · lore

In "tree" view, remove redundant "tree" link in the tree listing. It is identical to simply clicking on the tree entry itself.

Signed-off-by: Luben Tuikov <ltuikov@yahoo.com>
---
 gitweb/gitweb.perl |   16 ++++++----------
 1 files changed, 6 insertions(+), 10 deletions(-)
Show changes to gitweb/gitweb.perl +6 −10
diff --git a/gitweb/gitweb.perl b/gitweb/gitweb.perl
index 959e3f9..8e9c827 100755
--- a/gitweb/gitweb.perl
+++ b/gitweb/gitweb.perl
@@ -1631,18 +1631,14 @@ sub git_print_tree_entry {
 		print "</td>\n";
 
 	} elsif ($t->{'type'} eq "tree") {
-		print "<td class=\"list\">" .
-		      $cgi->a({-href => href(action=>"tree", hash=>$t->{'hash'},
-		                             file_name=>"$basedir$t->{'name'}", %base_key)},
-		              esc_html($t->{'name'})) .
-		      "</td>\n" .
-		      "<td class=\"link\">" .
-		      $cgi->a({-href => href(action=>"tree", hash=>$t->{'hash'},
+		print "<td class=\"list\">";
+		print $cgi->a({-href => href(action=>"tree", hash=>$t->{'hash'},
 		                             file_name=>"$basedir$t->{'name'}", %base_key)},
-		              "tree");
+		              esc_html($t->{'name'}));
+		print "</td>\n";
+		print "<td class=\"link\">";
 		if (defined $hash_base) {
-			print " | " .
-			      $cgi->a({-href => href(action=>"history", hash_base=>$hash_base,
+			print $cgi->a({-href => href(action=>"history", hash_base=>$hash_base,
 			                             file_name=>"$basedir$t->{'name'}")},
 			              "history");
 		}
-- 
1.4.2.1.g893b0
Jakub Narebski· Sep 26, 2006, 20:27 UTC · re: Luben Tuikov · lore

Re: [PATCH] gitweb: Remove redundant "tree" link

Luben Tuikov wrote:
> In "tree" view, remove redundant "tree" link in the tree
> listing.  It is identical to simply clicking on the tree
> entry itself.
I'd rather have this redundancy.
-- 
Jakub Narebski
Warsaw, Poland
ShadeHawk on #git

← back to recent threads