Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2019-04-25 10:41:15 +0300
committerJunio C Hamano <gitster@pobox.com>2019-04-25 10:41:15 +0300
commitda924b58ed3e2727e6ae2efc471db466a6178e2f (patch)
tree197c49bda6527fa17ec845d3d03377a4859834dc /builtin
parenta5e4be2f683f48a3edbbf9375af923a8256efb81 (diff)
parent79e3aa66244af40bd3c8999e00308f96748367d0 (diff)
Merge branch 'sg/index-pack-progress'
A progress indicator has been added to the "index-pack" step, which often makes users wait for completion during "git clone". * sg/index-pack-progress: index-pack: show progress while checking objects
Diffstat (limited to 'builtin')
-rw-r--r--builtin/index-pack.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/builtin/index-pack.c b/builtin/index-pack.c
index 31046c7a0a..ccf4eb7e9b 100644
--- a/builtin/index-pack.c
+++ b/builtin/index-pack.c
@@ -219,8 +219,16 @@ static unsigned check_objects(void)
unsigned i, max, foreign_nr = 0;
max = get_max_object_index();
- for (i = 0; i < max; i++)
+
+ if (verbose)
+ progress = start_delayed_progress(_("Checking objects"), max);
+
+ for (i = 0; i < max; i++) {
foreign_nr += check_object(get_indexed_object(i));
+ display_progress(progress, i + 1);
+ }
+
+ stop_progress(&progress);
return foreign_nr;
}