git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH v2 3/3] rev-parse: match ^{<type>} case-insensitively

From
Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Date
Mar 27, 2017, 07:33 UTC
Message-ID
<CACBZZX78ppO5M5oGEDxoHxs5VtXpLRf9ivNxmT7bGw_5aQa8qA@mail.gmail.com>
In-Reply-To
<20170327025818.pbm4nwqrfolyto7g@sigill.intra.peff.net>
On Mon, Mar 27, 2017 at 4:58 AM, Jeff King <peff@peff.net> wrote:
Show 29 quoted lines
> On Sun, Mar 26, 2017 at 05:36:21PM -0700, Junio C Hamano wrote:
>
>> It's not "potential confusion".  This closes the door for us to
>> introduce "TREE" as a separate object type in the future.
>>
>> If we agree to make a declaration that all typenames are officially
>> spelled in lowercase [*1*] and at the UI level we accept typenames
>> spelled in any case, then we can adopt this change (and then we need
>> to update "cat-file -t" etc. to match it).
>>
>> I do not at all mind to see if the list concensus is to make such a
>> declaration and permanently close the door for typenames that are
>> not lowercase, and after seeing such a concensus I'd gladly
>> appreciate this patch, but I do not want to see a change like this
>> that decides the future of the system, pretending as an innocuous
>> change, sneaked in without making sure that everybody is aware of
>> its implications.
>
> FWIW, I cannot see us ever adding TREE (or Tree) as a separate type.
> It's too confusing for no gain. We'd call it "tree2" or something more
> obvious.
>
> So I don't mind closing that door, but I'm not sure if a partial
> conversion (where some commands are case-insensitive but others aren't
> yet) might not leave us in a more confusing place.
>
> I dunno. I guess I have never wanted to type "^{Tree}" in the first
> place, so I do not personally see the _benefit_. Which makes it easy to
> see even small negatives as a net loss.
I don't either, I think this patch should just be dropped.

As noted in the cover letter[1] I carved this off from the rest of the series just in case anyone wanted this, either now or in the future.

I originally implemented this for consistency with @{U} because it's another thing that can be made case-insensitive unambiguously as far as the rev-parse syntax is concerned, but as you/Junio note here the tree/blob/object etc. names exist in a lot more places, so just making this particular thing case insensitive wouldn't make sense, and has little benefit.

1. <20170326121654.22035-1-avarab@gmail.com>
Previous: Jeff KingNext: Ævar Arnfjörð Bjarmason
Message 21 of 24 in “rev-parse: match @{u}, @{push} and ^{<type>} case-insensitively”
  1. rev-parse: match @{u}, @{push} and ^{<type>} case-insensitivelyÆvar Arnfjörð Bjarmason, Mar 18, 2017
  2. Duy NguyenMar 19, 2017
  3. Ævar Arnfjörð BjarmasonMar 19, 2017
  4. Junio C HamanoMar 19, 2017
  5. Ævar Arnfjörð BjarmasonMar 19, 2017
  6. Junio C HamanoMar 19, 2017
  7. 0/3 rev-parse case insensitivity & @{p} synonymÆvar Arnfjörð Bjarmason, Mar 26, 2017
  8. 1/3 rev-parse: match @{upstream}, @{u} and @{push} case-insensitivelyÆvar Arnfjörð Bjarmason, Mar 26, 2017
  9. Junio C HamanoMar 27, 2017
  10. rev-parse: match @{upstream}, @{u} and @{push} case-insensitivelyÆvar Arnfjörð Bjarmason, Mar 27, 2017
  11. Junio C HamanoMar 27, 2017
  12. Ævar Arnfjörð BjarmasonMar 27, 2017
  13. 2/3 rev-parse: add @{p} as a synonym for @{push}Ævar Arnfjörð Bjarmason, Mar 26, 2017
  14. Jeff KingMar 27, 2017
  15. Ævar Arnfjörð BjarmasonMar 27, 2017
  16. 3/3 rev-parse: match ^{<type>} case-insensitivelyÆvar Arnfjörð Bjarmason, Mar 26, 2017
  17. Junio C HamanoMar 27, 2017
  18. Jeff KingMar 27, 2017
  19. Junio C HamanoMar 27, 2017
  20. Jeff KingMar 27, 2017
  21. Ævar Arnfjörð BjarmasonMar 27, 2017
  22. Ævar Arnfjörð BjarmasonMar 21, 2017
  23. Junio C HamanoMar 21, 2017
  24. Jeff KingMar 21, 2017

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.