git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] Recommend "git gc --auto" instead of "git prune"

From
Junio C Hamano <gitster@pobox.com>
Date
Jun 8, 2020, 17:34 UTC
Message-ID
<xmqqd069law7.fsf@gitster.c.googlers.com>
In-Reply-To
<20200607204531.GA2313@generichostname>
Denton Liu <liu.denton@gmail.com> writes:
Show 14 quoted lines
>> Correct.  When running manually, after noticing the need to do a GC,
>> it is a mental bug to add "--auto" to it, I would think.
>
> Sorry about the confusion, when I was responding to the original
> issue[0], I mistakenly typed the wrong thing. I meant to suggest
> replacing it with `git gc --prune=now`, _not_ `git gc --auto` but I
> guess I had my wires crossed. With this in mind...
>
> The rationale behind this change is that John wanted to add bash
> completions for `git prune`. However, I noted that prune is a plumbing
> command and users should opt to use `git gc` instead. He mentioned that
> sometimes when auto gc runs, it tells the user that they should run
> `git prune` so I suggested (meant to suggest) replacing the command with
> `git gc --prune=now` instead so that users could call the porcelain.

Nice to know. The reasoning behind the change should be available to those who only look at "git show".

John, if you are to send an updated patch, please make sure you have a meaningful log message in it.

Thanks.
Previous: Denton Liu
Message 5 of 5 in “Recommend "git gc --auto" instead of "git prune"”
  1. Recommend "git gc --auto" instead of "git prune"John Lin via GitGitGadget, Jun 7, 2020
  2. brian m. carlsonJun 7, 2020
  3. Junio C HamanoJun 7, 2020
  4. Denton LiuJun 7, 2020
  5. Junio C HamanoJun 8, 2020

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.