From: Tony Finch Date: Thu, 31 Jul 2014 12:53:54 GMT Subject: [PATCH 5/5] gitweb: make category headings into links when they are directories Message-ID: When $projects_list_category_is_directory is turned on, project categories can be useful as project filters, so with that setting gitweb now makes the category headings into project_filter links (like the breadcrumbs). Signed-off-by: Tony Finch --- gitweb/gitweb.perl | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/gitweb/gitweb.perl b/gitweb/gitweb.perl index edbc058..32e65ae 100755 --- a/gitweb/gitweb.perl +++ b/gitweb/gitweb.perl @@ -5834,8 +5834,18 @@ sub git_project_list_body { if ($check_forks) { print "\n"; } - print "".esc_html($cat)."\n"; - print "\n"; + print ""; + if ($projects_list_directory_is_category) { + print $cgi->a({-href => + href(project => undef, + project_filter => $cat, + action => "project_list"), + -class => "list"}, + esc_html($cat)); + } else { + print esc_html($cat); + } + print "\n\n"; } git_project_list_rows($categories{$cat}, undef, undef, $check_forks); -- 2.1.0.rc0.229.gaee38de