git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Job Snijders <job@instituut.net>
To: git@vger.kernel.org
Cc: avarab@gmail.com, yashi@atmark-techno.com,
	giuseppe.bilotta@gmail.com, jnareb@gmail.com
Subject: Re: [PATCH] Add 'raw' blob_plain link in history overview
Date: Sun, 20 Aug 2017 20:03:32 +0200	[thread overview]
Message-ID: <20170820180332.GC39363@Vurt.local> (raw)
In-Reply-To: <20170802185901.GA27243@Vurt.local>

bump? 

On Wed, Aug 02, 2017 at 08:59:01PM +0200, Job Snijders wrote:
> We often work with very large plain text files in our repositories and
> found it friendlier to the users if we can click directly to the raw
> version of such files.
> 
> This patch adds a 'raw' blob_plain link in history overview.
> 
> Signed-off-by: Job Snijders <job@instituut.net>
> ---
>  gitweb/gitweb.perl | 7 +++++--
>  1 file changed, 5 insertions(+), 2 deletions(-)
> 
> diff --git a/gitweb/gitweb.perl b/gitweb/gitweb.perl
> index 3d4a8ee27..ad79c518e 100755
> --- a/gitweb/gitweb.perl
> +++ b/gitweb/gitweb.perl
> @@ -5961,8 +5961,11 @@ sub git_history_body {
>  		                          href(action=>"commit", hash=>$commit), $ref);
>  		print "</td>\n" .
>  		      "<td class=\"link\">" .
> -		      $cgi->a({-href => href(action=>$ftype, hash_base=>$commit, file_name=>$file_name)}, $ftype) . " | " .
> -		      $cgi->a({-href => href(action=>"commitdiff", hash=>$commit)}, "commitdiff");
> +		      $cgi->a({-href => href(action=>$ftype, hash_base=>$commit, file_name=>$file_name)}, $ftype) . " | ";
> +		if ($ftype eq 'blob') {
> +			print $cgi->a({-href => href(action=>"blob_plain", hash_base=>$commit, file_name=>$file_name)}, "raw") . " | ";
> +		}
> +		print $cgi->a({-href => href(action=>"commitdiff", hash=>$commit)}, "commitdiff");
>  
>  		if ($ftype eq 'blob') {
>  			my $blob_current = $file_hash;

  reply	other threads:[~2017-08-20 18:03 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-02 18:59 [PATCH] Add 'raw' blob_plain link in history overview Job Snijders
2017-08-20 18:03 ` Job Snijders [this message]
2017-08-21 10:19   ` Giuseppe Bilotta
2017-08-21 10:44     ` Job Snijders
2017-08-21 14:07       ` Giuseppe Bilotta
2017-08-21 14:13         ` Job Snijders
2017-08-22 19:22           ` Junio C Hamano
2017-08-22 19:35             ` Job Snijders
2017-08-22 20:00               ` Giuseppe Bilotta
2017-08-22 20:07                 ` Job Snijders
2017-08-22 20:09                   ` Junio C Hamano
2017-08-22 20:06               ` Junio C Hamano

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170820180332.GC39363@Vurt.local \
    --to=job@instituut.net \
    --cc=avarab@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=giuseppe.bilotta@gmail.com \
    --cc=jnareb@gmail.com \
    --cc=yashi@atmark-techno.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).