@matheusbsbs / matheus-bagliano / commits / eeebd8d8c5
Fork 0

git-svn: Protect against "diff.color = true".

If the configuration of the user has "diff.color = true", the output from "log" we invoke internally added color codes, which broke the parser. Signed-off-by: Junio C Hamano <gitster@pobox.com> Tested-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Acked-by: Eric Wong <normalperson@yhbt.net>

Junio C Hamano committed Aug 31, 2007 at 14:29 UTC eeebd8d8c5ab63494abe200b30a840aa99ee7412
1 file changed +2 -2
git-svn.perl
+2 -2
@@ -807,7 +807,7 @@ sub cmt_metadata {
807
808 sub working_head_info {
809 my ($head, $refs) = @_;
810 - my ($fh, $ctx) = command_output_pipe('log', $head);
810 + my ($fh, $ctx) = command_output_pipe('log', '--no-color', $head);
811 my $hash;
812 my %max;
813 while (<$fh>) {
@@ -2072,7 +2072,7 @@ sub rebuild {
2072 return;
2073 }
2074 print "Rebuilding $db_path ...\n";
2075 - my ($log, $ctx) = command_output_pipe("log", $self->refname);
2075 + my ($log, $ctx) = command_output_pipe("log", '--no-color', $self->refname);
2076 my $latest;
2077 my $full_url = $self->full_url;
2078 remove_username($full_url);