summaryrefslogtreecommitdiff
path: root/builtin/commit.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2020-05-13 19:19:19 (GMT)
committerJunio C Hamano <gitster@pobox.com>2020-05-13 19:19:19 (GMT)
commit3af459e48dd275665568f3a7a6d76d90c1843e6a (patch)
tree7c6dd38b823daf85193e2044a3f696ec9ad3c7fe /builtin/commit.c
parentaa28171c2752c0aa04c2e25f2f79bc01a7f045d5 (diff)
parent7c3e9e8cfbf6a8e45f4745049dc58f5c9e9d1eb9 (diff)
downloadgit-3af459e48dd275665568f3a7a6d76d90c1843e6a.zip
git-3af459e48dd275665568f3a7a6d76d90c1843e6a.tar.gz
git-3af459e48dd275665568f3a7a6d76d90c1843e6a.tar.bz2
Merge branch 'jc/auto-gc-quiet'
Teach "am", "commit", "merge" and "rebase", when they are run with the "--quiet" option, to pass "--quiet" down to "gc --auto". * jc/auto-gc-quiet: auto-gc: pass --quiet down from am, commit, merge and rebase auto-gc: extract a reusable helper from "git fetch"
Diffstat (limited to 'builtin/commit.c')
-rw-r--r--builtin/commit.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/builtin/commit.c b/builtin/commit.c
index a73de0a..d1b7396 100644
--- a/builtin/commit.c
+++ b/builtin/commit.c
@@ -1494,7 +1494,6 @@ static int git_commit_config(const char *k, const char *v, void *cb)
int cmd_commit(int argc, const char **argv, const char *prefix)
{
- const char *argv_gc_auto[] = {"gc", "--auto", NULL};
static struct wt_status s;
static struct option builtin_commit_options[] = {
OPT__QUIET(&quiet, N_("suppress summary after successful commit")),
@@ -1703,7 +1702,7 @@ int cmd_commit(int argc, const char **argv, const char *prefix)
git_test_write_commit_graph_or_die();
repo_rerere(the_repository, 0);
- run_command_v_opt(argv_gc_auto, RUN_GIT_CMD);
+ run_auto_gc(quiet);
run_commit_hook(use_editor, get_index_file(), "post-commit", NULL);
if (amend && !no_post_rewrite) {
commit_post_rewrite(the_repository, current_head, &oid);