Re: [PATCH] ls-remote: create option to sort by versions
- From
Harald Nordgren <haraldnordgren@gmail.com>
- Date
- Apr 2, 2018, 20:03 UTC
- Message-ID
- <CAHwyqnV8tB63gQFVJhyNtr304Uv1TwWvYiX+3wuU0fDFhOphgg@mail.gmail.com>
- In-Reply-To
- <xmqqbmf1zcfb.fsf@gitster-ct.c.googlers.com>
Thanks for all the discussion!
I think I figured out a way to reuse more ref-filter.c machinery. I will submit another patchset shortly.
On Mon, Apr 2, 2018 at 8:32 PM, Junio C Hamano <gitster@pobox.com> wrote:
Show 15 quoted lines
> Ævar Arnfjörð Bjarmason <avarab@gmail.com> writes: > >> This is a sensible thing to want, but why not follow the UI we have for >> this with git-tag? I.e. --sort=<key> & -i (or --ignore-case)? Of course >> ls-remote doesn't just show tags, so maybe we'd want --tag-sort=<key> >> and --ignore-tag-case or something, but the rest should be equivalent, >> no? > > Yeah, and if we can reuse more of ref-filter.c machinery (which was > factored out of for-each-ref and tag you suggested borrows from), > that would be even better. In the context of ls-remote, however, we > cannot inspect the object (we typically do not have them yet), so it > may not be practical, but I agree with your suggestion---we should > match the behaviour at the UI level at least when we can. >