Message ID | 42113e20dd7f2a80bbe09c01f1aedfcdfdbf6ae2.1605051739.git.gitgitgadget@gmail.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | Fix color handling in git add -i | expand |
diff --git a/git-add--interactive.perl b/git-add--interactive.perl index e713fe3d02..adbac2bc6d 100755 --- a/git-add--interactive.perl +++ b/git-add--interactive.perl @@ -483,10 +483,8 @@ sub list_and_choose { my $last_lf = 0; if ($opts->{HEADER}) { - if (!$opts->{LIST_FLAT}) { - print " "; - } - print colored $header_color, "$opts->{HEADER}\n"; + my $indent = $opts->{LIST_FLAT} ? "" : " "; + print colored $header_color, "$indent$opts->{HEADER}\n"; } for ($i = 0; $i < @stuff; $i++) { my $chosen = $chosen[$i] ? '*' : ' ';