summaryrefslogtreecommitdiff
path: root/builtin/gc.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2019-07-09 22:25:36 (GMT)
committerJunio C Hamano <gitster@pobox.com>2019-07-09 22:25:36 (GMT)
commite1168940ce11878261ece4602a7d8b8ee9a8c77e (patch)
tree167523cf6bc8dd4f070c275febb228da7bc84177 /builtin/gc.c
parente9eaaa46906753ca8958df33328a0590b0287166 (diff)
parent238def57fe7ba219c9e50094512fff1068ac5413 (diff)
downloadgit-e1168940ce11878261ece4602a7d8b8ee9a8c77e.zip
git-e1168940ce11878261ece4602a7d8b8ee9a8c77e.tar.gz
git-e1168940ce11878261ece4602a7d8b8ee9a8c77e.tar.bz2
Merge branch 'ds/commit-graph-write-refactor'
Renamed from commit-graph-format-v2 and changed scope. * ds/commit-graph-write-refactor: commit-graph: extract write_commit_graph_file() commit-graph: extract copy_oids_to_commits() commit-graph: extract count_distinct_commits() commit-graph: extract fill_oids_from_all_packs() commit-graph: extract fill_oids_from_commit_hex() commit-graph: extract fill_oids_from_packs() commit-graph: create write_commit_graph_context commit-graph: remove Future Work section commit-graph: collapse parameters into flags commit-graph: return with errors during write commit-graph: fix the_repository reference
Diffstat (limited to 'builtin/gc.c')
-rw-r--r--builtin/gc.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/builtin/gc.c b/builtin/gc.c
index 8943bcc..8ba9bd2 100644
--- a/builtin/gc.c
+++ b/builtin/gc.c
@@ -685,9 +685,10 @@ int cmd_gc(int argc, const char **argv, const char *prefix)
clean_pack_garbage();
}
- if (gc_write_commit_graph)
- write_commit_graph_reachable(get_object_directory(), 0,
- !quiet && !daemonized);
+ if (gc_write_commit_graph &&
+ write_commit_graph_reachable(get_object_directory(),
+ !quiet && !daemonized ? COMMIT_GRAPH_PROGRESS : 0))
+ return 1;
if (auto_gc && too_many_loose_objects())
warning(_("There are too many unreachable loose objects; "