From 7a132c628e57b9bceeb88832ea051395c0637b16 Mon Sep 17 00:00:00 2001 From: Matheus Tavares Date: Thu, 26 Aug 2021 16:10:06 -0300 Subject: checkout: make delayed checkout respect --quiet and --no-progress The 'Filtering contents...' progress report from delayed checkout is displayed even when checkout and clone are invoked with --quiet or --no-progress. Furthermore, it is displayed unconditionally, without first checking whether stdout is a tty. Let's fix these issues and also add some regression tests for the two code paths that currently use delayed checkout: unpack_trees.c:check_updates() and builtin/checkout.c:checkout_worktree(). Signed-off-by: Matheus Tavares Signed-off-by: Junio C Hamano --- entry.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'entry.h') diff --git a/entry.h b/entry.h index b8c0e170dc..7c889e58fd 100644 --- a/entry.h +++ b/entry.h @@ -43,7 +43,8 @@ static inline int checkout_entry(struct cache_entry *ce, } void enable_delayed_checkout(struct checkout *state); -int finish_delayed_checkout(struct checkout *state, int *nr_checkouts); +int finish_delayed_checkout(struct checkout *state, int *nr_checkouts, + int show_progress); /* * Unlink the last component and schedule the leading directories for -- cgit v1.2.1