[PATCH] gitk: Show notes

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



If in git.git I do

    $ git notes add -m 'This makes status significantly slower with Dokko' \
        ee6fc514

then `git log` shows the note...

    $ git log -1 ee6fc514

    commit ee6fc514f2df821c2719cc49499a56ef2fb136b0
    Author: Jens Lehmann <Jens.Lehmann@xxxxxx>
    Date:   Sat Jan 16 18:42:24 2010 +0100

        Show submodules as modified when they contain a dirty work tree

        Until now a submodule only then showed up as modified in the supermodule
        when the last commit in the submodule differed from the one in the index
        or the diffed against commit of the superproject. A dirty work tree
        containing new untracked or modified files in a submodule was
        undetectable when looking at it from the superproject.

        Now git status and git diff (against the work tree) in the superproject
        will also display submodules as modified when they contain untracked or
        modified files, even if the compared ref matches the HEAD of the
        submodule.

        Signed-off-by: Jens Lehmann <Jens.Lehmann@xxxxxx>
        Signed-off-by: Nanako Shiraishi <nanako3@xxxxxxxxxxx>
        Signed-off-by: Junio C Hamano <gitster@xxxxxxxxx>

    Notes:
        This makes status significantly slower with Dokko

... but unfortunately gitk does not.

Let's fix this and teach gitk to show notes.

Signed-off-by: Kirill Smelkov <kirr@xxxxxxxxxx>
---
 gitk |   11 ++++++-----
 1 files changed, 6 insertions(+), 5 deletions(-)

diff --git a/gitk b/gitk
index 1b0e09a..d537011 100755
--- a/gitk
+++ b/gitk
@@ -361,8 +361,8 @@ proc start_rev_list {view} {
     }
 
     if {[catch {
-	set fd [open [concat | git log --no-color -z --pretty=raw --parents \
-			 --boundary $args "--" $files] r]
+	set fd [open [concat | git log --no-color -z --pretty=raw --show-notes \
+			--parents --boundary $args "--" $files] r]
     } err]} {
 	error_popup "[mc "Error executing git log:"] $err"
 	return 0
@@ -508,8 +508,8 @@ proc updatecommits {} {
 	set args $vorigargs($view)
     }
     if {[catch {
-	set fd [open [concat | git log --no-color -z --pretty=raw --parents \
-			  --boundary $args "--" $vfilelimit($view)] r]
+	set fd [open [concat | git log --no-color -z --pretty=raw --show-notes \
+			--parents --boundary $args "--" $vfilelimit($view)] r]
     } err]} {
 	error_popup "[mc "Error executing git log:"] $err"
 	return
@@ -1586,7 +1586,8 @@ proc do_readcommit {id} {
     global tclencoding
 
     # Invoke git-log to handle automatic encoding conversion
-    set fd [open [concat | git log --no-color --pretty=raw -1 $id] r]
+    set fd [open [concat | git log --no-color --pretty=raw --show-notes \
+		     -1 $id] r]
     # Read the results using i18n.logoutputencoding
     fconfigure $fd -translation lf -eofchar {}
     if {$tclencoding != {}} {
-- 
1.7.1.89.g6b35c

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]