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

Re: [PATCH v2 0/8] builtin/maintenance: implement missing tasks compared to git-gc(1)

From
Derrick Stolee <stolee@gmail.com>
Date
Apr 30, 2025, 10:37 UTC
Message-ID
<732db882-f27c-4619-91cb-2cc291a7c7d5@gmail.com>
In-Reply-To
<20250430-pks-maintenance-missing-tasks-v2-0-2580b7b8ca3a@pks.im>
On 4/30/2025 6:25 AM, Patrick Steinhardt wrote:
Show 23 quoted lines
> Hi,
> 
> this small patch series implements the last couple of remaining tasks
> that are missing compared to the functionality git-gc(1) provides.
> 
> Right now, git-maintenance(1) still executes git-gc(1). With these last
> gaps plugged though we can in theory fully replace git-gc(1) with finer
> grained tasks without losing any functionality. The benefit is that it
> becomes possible for users to have finer-grained control over what
> exactly the maintenance does.
> 
> This patch series doesn't do that yet, but only implements whatever is
> needed to get there.
> 
> Changes in v2:
>   - Introduce "maintenance.worktree-prune.auto", which controls how many
>     stale worktrees need to exist before executing `git worktree prune`.
>   - Introduce "maintenance.rerere-gc.auto", which controls how many
>     stale rerere entries need to exist before executing `git rerere gc`.
>   - Add tests to verify that "gc.worktreePruneExpire" works.
>   - Remove some fragile test logic by introducing functions that check
>     for a given maintenance subprocess.
>   - Link to v1: https://lore.kernel.org/r/20250425-pks-maintenance-missing-tasks-v1-0-972ed6ab2c0d@pks.im

This version satisfies my comments from v1 and builds further by including the maintenance.<task>.auto config options.

LGTM. Thanks, -Stolee

Previous: Patrick Steinhardt
Message 14 of 14 in “builtin/maintenance: implement missing tasks compared to git-gc(1)”
  1. 0/8 builtin/maintenance: implement missing tasks compared to git-gc(1)Patrick Steinhardt, Apr 30, 2025
  2. 1/8 builtin/gc: fix indentation of `cmd_gc()` parametersPatrick Steinhardt, Apr 30, 2025
  3. 2/8 builtin/gc: remove global variables where it trivial to doPatrick Steinhardt, Apr 30, 2025
  4. 3/8 builtin/gc: move pruning of worktrees into a separate functionPatrick Steinhardt, Apr 30, 2025
  5. 4/8 worktree: expose function to retrieve worktree namesPatrick Steinhardt, Apr 30, 2025
  6. 5/8 builtin/maintenance: introduce "worktree-prune" taskPatrick Steinhardt, Apr 30, 2025
  7. 6/8 rerere: provide function to collect stale entriesPatrick Steinhardt, Apr 30, 2025
  8. Junio C HamanoApr 30, 2025
  9. Patrick SteinhardtMay 2, 2025
  10. Junio C HamanoMay 2, 2025
  11. Patrick SteinhardtMay 5, 2025
  12. 7/8 builtin/gc: move rerere garbage collection into separate functionPatrick Steinhardt, Apr 30, 2025
  13. 8/8 builtin/maintenance: introduce "rerere-gc" taskPatrick Steinhardt, Apr 30, 2025
  14. Derrick StoleeApr 30, 2025

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.