From: Junio C Hamano Date: Sun, 27 Aug 2017 05:55:07 +0000 (-0700) Subject: Merge branch 'js/gitweb-raw-blob-link-in-history' X-Git-Tag: v2.15.0-rc0~121 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/2adb614902ca4dbf085b880ee5bcfea8c2dafb08?hp=-c Merge branch 'js/gitweb-raw-blob-link-in-history' "gitweb" shows a link to visit the 'raw' contents of blbos in the history overview page. * js/gitweb-raw-blob-link-in-history: gitweb: add 'raw' blob_plain link in history overview --- 2adb614902ca4dbf085b880ee5bcfea8c2dafb08 diff --combined gitweb/gitweb.perl index 9208f42ed1,6be4c50af0..959f04b494 --- a/gitweb/gitweb.perl +++ b/gitweb/gitweb.perl @@@ -3071,8 -3071,6 +3071,8 @@@ sub git_get_projects_list return if (m!^[/.]$!); # only directories can be git repositories return unless (-d $_); + # need search permission + return unless (-x $_); # don't traverse too deep (Find is super slow on os x) # $project_maxdepth excludes depth of $projectroot if (($File::Find::name =~ tr!/!!) - $pfxdepth > $project_maxdepth) { @@@ -5967,6 -5965,9 +5967,9 @@@ sub git_history_body $cgi->a({-href => href(action=>"commitdiff", hash=>$commit)}, "commitdiff"); if ($ftype eq 'blob') { + print " | " . + $cgi->a({-href => href(action=>"blob_plain", hash_base=>$commit, file_name=>$file_name)}, "raw"); + my $blob_current = $file_hash; my $blob_parent = git_get_hash_by_path($commit, $file_name); if (defined $blob_current && defined $blob_parent &&