Skip to content

gitk support for git log -L

Thomas Rast git 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest4 patches 9 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4gitk: refactor per-line part of getblobdiffline and its supportgitk+213 -1950 replies
2/4gitk: split out diff part in $commitinfogitk+7 -10 replies
3/4gitk: support showing the gathered inline diffsgitk+38 -00 replies
4/4gitk: recognize -L optiongitk+8 -00 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH gitk 0/4] gitk support for git log -L

Now that git log -L has hit master, I figure it's time to discuss the corresponding change to gitk.

The hard part is that AFAICS this is the first history display accessible through gitk that can only be computed in one go. The existing displays all work by having git-log perform a preliminary search for the involved commits (or in some cases, only part of the range while we fetch more). log -L has to compute all the diffs anyway, so nothing can be saved by attempting this; it is better to load everything in bulk from a single git-log invocation.

Thus, patches 1--3 implement the infrastructure required to be able to work from a single git-log command.

I would have loved to instead make a feature that also generalizes to

  git log --parents <whatever> | gitk --read-stdin

(or some other similar option). This would make for much easier testing of new git-log options. Unfortunately this seems much harder to achieve in the current structure of gitk.

Note: all my Tk-ing is computationally indistinguishable from cargo culting. Please review with a grain of salt.

Thomas Rast (4):
gitk: refactor per-line part of getblobdiffline and its support
gitk: split out diff part in $commitinfo
gitk: support showing the gathered inline diffs
gitk: recognize -L option

 gitk | 462 ++++++++++++++++++++++++++++++++++++++-----------------------------
 1 file changed, 266 insertions(+), 196 deletions(-)
Signature · 1 line
1.8.3.496.g0d0267b