Skip to content

Commit 38920dd

Browse files
marcowsgitster
authored andcommitted
git-status -v: color diff output when color.ui is set
When using "git status -v", the diff output wasn't colored, even though color.ui was set. Only when setting color.diff it worked. Signed-off-by: Markus Heidelberg <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 3f4b609 commit 38920dd

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

builtin-commit.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -866,6 +866,9 @@ int cmd_status(int argc, const char **argv, const char *prefix)
866866
if (wt_status_use_color == -1)
867867
wt_status_use_color = git_use_color_default;
868868

869+
if (diff_use_color_default == -1)
870+
diff_use_color_default = git_use_color_default;
871+
869872
argc = parse_and_validate_options(argc, argv, builtin_status_usage, prefix);
870873

871874
index_file = prepare_index(argc, argv, prefix);

0 commit comments

Comments
 (0)