From: Junio C Hamano Date: Wed, 05 Feb 2025 14:09:00 GMT Subject: Re: [PATCH v5 0/7] Enable doing a shallow clone of a specific git revision Message-ID: In-Reply-To: <20250204-toon-clone-refs-v5-0-37e34af283c8@iotcl.com> Toon Claes writes: > The goal of this series is to add an option `--revision` to > git-clone(1). > > This series starts with a handful of preparatory refactoring commits > that make it more straight-forward to add this new option. In the last > commit we're actually adding the feature. > > This series sets an example on how I think we can further refactor > builtin/clone.c to increase the maintainability of the code. > > --- > Changes in v5: > - Add separate commit to introduce die_for_incompatible_opt2() > - Small tweaks in documentation about `--[no-]tags` and `--revision`. > - Better explain the refactoring of wanted_peer_refs() in the commit > message. > - Change type from `int` to `size_t` in wanted_peer_refs(). > - Use lookup_commit_or_die() instead lookup_commit_reference() to avoid > checking the result ourself. > - Add a few code comments to explain some things. > - Stylish cleanups like removal of unneeded empty lines, commented out > test-code and remarks. > - Link to v4: https://lore.kernel.org/r/20250131-toon-clone-refs-v4-0-2a4ff851498f@iotcl.com Looking good. Queued.