Harald Nordgren <haraldnordgren@xxxxxxxxx> writes: > Subject: Re: [PATCH] ls-remote: create '--sort' option It would be more helpful to mark as [PATCH v2] a rerolled patch like this. > Create a '--sort' option for ls-remote. This is useful e.g. for the Go > repository after the release of version 1.10, where by default v1.10 is > sorted before v1.2. See: > > $ git ls-remote -t https://go.googlesource.com/go Does this sample command line also need updating for the refined design? > ... > 205f850ceacfc39d1e9d76a9569416284594ce8c refs/tags/go1.1 > d260448f6b6ac10efe4ae7f6dfe944e72bc2a676 refs/tags/go1.1.1 > 1d6d8fca241bb611af51e265c1b5a2e9ae904702 refs/tags/go1.1.2 > bf86aec25972f3a100c3aa58a6abcbcc35bdea49 refs/tags/go1.10 > ac7c0ee26dda18076d5f6c151d8f920b43340ae3 refs/tags/go1.10.1 > ... > + git ls-remote --sort="-version:refname" --tags self >actual && > + test_cmp expect actual > +... > + git ls-remote --sort="-refname" --tags self >actual && These both look sensible (also the variant without the dash prefix which I omitted from the quote).