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

Creation of a branch named that has a directory prefix equal to the name of another branch fail.

From
TETommaso Ercole <tommaso.ercole@qlik.com>
Date
Jul 24, 2020, 10:26 UTC
Message-ID
<DM5PR1801MB20762477763E6298C7FE6315F0770@DM5PR1801MB2076.namprd18.prod.outlook.com>
In-Reply-To
<DM5PR1801MB2076F807C0B9F29A152DBEB7F0760@DM5PR1801MB2076.namprd18.prod.outlook.com>
As per compiled bug report, creation of a branch that has a prefix that map to a folder, when that prefix is just an existing branch in the repo fails.
I.E. 'a/b/c' when 'a/b' just exists.

Best regards, Tommaso Ercole Head Programmer Content Delivery

Mobile: +39 328 7182833
Email:  mailto:tommaso.ercole@qlik.com 
Skype:  live:tommaso.ercole

Qlik via Brescia 31 36040 Torri di Quartesolo - Vicenza - Italy

http://www.qlik.com/ http://qlik.com/

The information transmitted is intended only for the person or entity to which it is addressed and may contain confidential and/or privileged material. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited. If you received this in error, please contact the sender and delete the material from any computer.
Creating a branch a/b/c when a/b exists fails complaining that a ref 'a/b' just exists.

This is probably due to the fact that when creating a/b a directory 'a' is created inside 'refs/heads' and a file 'b' is created under the a directory, avoiding the subsequent possibility to create a folder 'b' in the same directory that is needed to create the ref for 'a/b/c'

The solution seems to append to the file an extension to disambiguate the file from the folder.

[System Info] git version: git version 2.27.0.windows.1 cpu: x86_64 built from commit: 907ab1011dce9112700498e034b974ba60f8b407 sizeof-long: 4 sizeof-size_t: 8 uname: Windows 10.0 18363 compiler info: gnuc: 10.1 libc info: no libc information available

[Enabled Hooks]
Next: Taylor Blau
Message 1 of 8 in “Creation of a branch named that has a directory prefix equal to the name of another branch fail.”
  1. Tommaso ErcoleJul 24, 2020
  2. Taylor BlauJul 24, 2020
  3. Jeff KingJul 24, 2020
  4. Junio C HamanoJul 24, 2020
  5. Tommaso ErcoleJul 27, 2020
  6. Bryan TurnerJul 27, 2020
  7. Han-Wen NienhuysJul 27, 2020
  8. Junio C HamanoJul 24, 2020

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.