Re: [GSoC][RFC PATCH 0/2] Add refs list subcommand
- From
shejialuo <shejialuo@gmail.com>
- Date
- Jul 6, 2025, 12:58 UTC
- Message-ID
- <aGpy8zQRsEjqX3mw@ArchLinux>
- In-Reply-To
- <xmqqo6u55npk.fsf@gitster.g>
On Mon, Jun 30, 2025 at 07:05:43AM -0700, Junio C Hamano wrote:
Show 8 quoted lines
> shejialuo <shejialuo@gmail.com> writes: > > > If so, we would make "git refs list" to place "git for-each-ref" at > > all. However, in the current implementation, we indeed introduce > > duplicate code path if we decide to do above. > > I do not know what you meant by your first sentence. >
Sorry, I think I made you confused here. My meaning is exactly below what you have said.
Show 6 quoted lines
> If you make "git refs list <anything>" a thin wrapper for "git > for-each-ref <anthing>", you can satisfy "I want to teach any and > all features related to references to the 'git refs' command" while > not penalizing existing users. After all, that is essentially what > "git branch" and "git tag" do as their listing mode and supports the > featurs from for-each-ref, isn't it?
That's right. I just want to let Meet know, if we decide to make "git refs list" a wrapper for "git for-each-ref", we need to change the current code design as we introduced repeated code path.
---
Sorry for the late reply, as I am extremely busy with my own business.
Thanks, Jialuo