gitk: disable colours when calling git log
authorSam Vilain <sam.vilain@catalyst.net.nz>
Tue, 16 Oct 2007 22:33:04 +0000 (11:33 +1300)
committerShawn O. Pearce <spearce@spearce.org>
Wed, 17 Oct 2007 07:44:28 +0000 (03:44 -0400)
If the user specifies 'diff.color = 1' in their configuration file,
then gitk will not start.  Disable colours when calling git log.

Signed-off-by: Sam Vilain <sam.vilain@catalyst.net.nz>
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
gitk

diff --git a/gitk b/gitk
index 300fdceb350ca6d0419ef3b0bf3f1e7b82700a59..999e3c2188ee25bbdfc8099b716a4f15569b0ebc 100755 (executable)
--- a/gitk
+++ b/gitk
@@ -92,7 +92,7 @@ proc start_rev_list {view} {
        set order "--date-order"
     }
     if {[catch {
-       set fd [open [concat | git log -z --pretty=raw $order --parents \
+       set fd [open [concat | git log --no-color -z --pretty=raw $order --parents \
                         --boundary $viewargs($view) "--" $viewfiles($view)] r]
     } err]} {
        error_popup "Error executing git rev-list: $err"