From: Derrick Stolee <stolee@gmail.com>
To: git@vger.kernel.org
Subject: Re: [PATCH 05/10] commit-graph: merge the two commit graph writers
Date: Wed, 4 Nov 2026 11:33:11 -0500 [thread overview]
Message-ID: <9a97d8ca-e7c9-4e57-905b-109df92a9eae@gmail.com> (raw)
In-Reply-To: <20261104-pks-commit-graph-write-refactorings-v1-5-d013d9401a59@pks.im>
On 11/4/2026 10:57 AM, Patrick Steinhardt wrote:
> We have two entry points for writing commit graphs:
>
> - `write_commit_graph()` either writes a commit graph for all commits
> in the object database, or for the commits specified via its options
> struct.
>
> - `write_commit_graph_reachable()` writes a commit graph for all
> reachable commits.
>
> It's somewhat pointless though to have a separate entry point for
> writing a commit graph for reachable commits, as this use case can be
> trivially satisfied via a flag.
>
> Introduce that flag and drop the separate entry point in favor of
> `write_commit_graph()`. This ensures we have a single entry point for
> writing commit graphs, only, which will make it easier to eventually
> introduce pluggable commit graphs via the object database.
The previous four patches were immediately obvious to be correct. This
one takes a little bit more work, but is a valuable simplification
that will lead to better code reuse in the future.
Thanks,
-Stolee
next prev parent reply other threads:[~2026-11-04 16:33 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-04 15:57 [PATCH 00/10] commit-graph: several refactorings for writing commit graphs Patrick Steinhardt
2026-11-04 15:57 ` [PATCH 01/10] commit-graph: rename `struct commit_graph_opts` Patrick Steinhardt
2026-11-04 15:57 ` [PATCH 02/10] commit-graph: pass writer flags via options Patrick Steinhardt
2026-11-04 15:57 ` [PATCH 03/10] commit-graph: drop `NULL` checks for write options Patrick Steinhardt
2026-11-04 15:57 ` [PATCH 04/10] commit-graph: drop redundant flags in write context Patrick Steinhardt
2026-11-04 15:57 ` [PATCH 05/10] commit-graph: merge the two commit graph writers Patrick Steinhardt
2026-11-04 16:33 ` Derrick Stolee [this message]
2026-11-04 15:57 ` [PATCH 06/10] commit-graph: move remaining write parameters into options Patrick Steinhardt
2026-11-04 16:34 ` Derrick Stolee
2026-11-04 15:57 ` [PATCH 07/10] commit-graph: fix mixup of write/verify flags Patrick Steinhardt
2026-11-04 15:57 ` [PATCH 08/10] builtin/commit-graph: set flags directly Patrick Steinhardt
2026-11-04 15:57 ` [PATCH 09/10] odb/source-files: verify commit-graphs as part of fsck Patrick Steinhardt
2026-11-04 15:57 ` [PATCH 10/10] commit-graph: modernize function names Patrick Steinhardt
2026-11-04 16:37 ` [PATCH 00/10] commit-graph: several refactorings for writing commit graphs Derrick Stolee
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=9a97d8ca-e7c9-4e57-905b-109df92a9eae@gmail.com \
--to=stolee@gmail.com \
--cc=git@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox