Subject: Re: GSoC idea: adding JavaScript library / framework in gitweb

From: Jakub Narebski <[email-masked]>
Date: Mon, 26 Mar 2012 01:44:22 +0100

On Sun, 25 Mar 2012, chaitanyaa nalla wrote:

> "creating side-by-side diff from unified  diff in JavaScript, so that
>  switching between unified and side-by-side diff view  could be done
>  entirely client-side, without hitting the server"
>
>  could you please elaborate on this, I didn't understand this completly. 

Side-by-side diff is a new gitweb feature, available in v.7.9 (since
commit 6ba1eb5 (gitweb: Add a feature to show side-by-side diff, 2011-10-31))

Both git.kernel.org and repo.or.cz are based on an older version of
gitweb.  You need to install gitweb to test this (and perhaps git-instaweb
for easier HTML preview).

In short: unified diff like this:

  @@ -119,8 +119,8 @@ UI, Workflows & Features
   ctx
  -foo
  +bar

is turned into side-by-side diff:

   ctx                    ctx
  -foo                   +bar

Commit  6ae683c (gitweb: Add navigation to select side-by-side diff,
2011-10-31) allows switching between unified and side-by-side diff;
the goal of this feature would be to make it client-side (hijacking
the link).

-- 
Jakub Narebski
Poland