All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH/RFC resend] gitk: Ignore limitdiffs option when displaying  commit file list
@ 2010-03-29 14:29 Tim Henigan
  0 siblings, 0 replies; only message in thread
From: Tim Henigan @ 2010-03-29 14:29 UTC (permalink / raw)
  To: Git Mailing List; +Cc: Paul Mackerras, Junio C Hamano, j.sixt, markb

When gitk is invoked with a path argument (e.g. gitk gitk-git),
the path is used to filter the list of files displayed in the
lower right window.  If a file does not start with the specified
substring, it is not displayed.  This is counter-intuitive for
a couple reasons:
 1) The files continue to be listed in the diff window.
 2) Merge commits (i.e. commits with more than 1 parent) still
    show the complete list of files in the lower right since
    these commits are processed by 'mergediff' rather than
    the 'startdiff' function.

With this change, the complete list of files affected by a
commit will always be shown in the lower right window.

Signed-off-by: Tim Henigan <tim.henigan@gmail.com>
---

This is a resend with Paul Mackerras added to the CC list.

I noticed this issue recently when trying gitk.  After some research, I found
this thread [1] which explained the issue.  However, the operation still does
not seem consistent.  This patch fixes the "problem" that I encountered, but
I can't help wondering:
   1) I am breaking another feature?  Especially since the
        '$vfilelimit($curview) ne {}' check is now ignored.
   2) Can the limitdiffs option be completely removed?  If not, the behavior
       of startdiff and mergediff should at least be made consistent.

I copied the people that were involved in the earlier thread [1].

[1] http://thread.gmane.org/gmane.comp.version-control.git/133088

 gitk-git/gitk |   12 +-----------
 1 files changed, 1 insertions(+), 11 deletions(-)

diff --git a/gitk-git/gitk b/gitk-git/gitk
index 1f36a3e..518061e 100644
--- a/gitk-git/gitk
+++ b/gitk-git/gitk
@@ -7450,17 +7450,7 @@ proc gettreediffline {gdtf ids} {
       return [expr {$nr >= $max? 2: 1}]
    }
    close $gdtf
-    if {$limitdiffs && $vfilelimit($curview) ne {}} {
-       set flist {}
-       foreach f $treediff {
-           if {[path_filter $vfilelimit($curview) $f]} {
-               lappend flist $f
-           }
-       }
-       set treediffs($ids) $flist
-    } else {
-       set treediffs($ids) $treediff
-    }
+    set treediffs($ids) $treediff
    unset treepending
    if {$cmitmode eq "tree" && [llength $diffids] == 1} {
       gettree $diffids
--
1.7.0.3.291.g5e4f6.dirty

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2010-03-29 14:29 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-03-29 14:29 [PATCH/RFC resend] gitk: Ignore limitdiffs option when displaying commit file list Tim Henigan

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.