git/list[1] front-page[2] threads[3] people[4] search[5] about
wed 2026-10-07 16:57 UTC

Re: not robust inconsistent git 2.40.1 with HEAD -> master, origin/main, origin/HEAD, origin/master, main

From
Philip Oakley <philipoakley@iee.email>
Date
May 31, 2023, 10:57 UTC
Message-ID
<319cfa79-a508-127f-c201-9f50d5e6fe6a@iee.email>
In-Reply-To
<lxh4jpacuv5ivqp35w5vpbcjlw67r7ix3yog6cc3cu5ij7yqho@mrtr24xxdstx>
On 30/05/2023 19:14, Carlos wrote:
Show 9 quoted lines
> Running git 2.40.1 with HEAD -> master, origin/main, origin/HEAD, origin/master, main with initial commit on main does not show all the objects from master
> 
> 
> ! [main] Initial commit
>  * [master] Initial commit
>   ! [origin/master] Initial commit
> ---
> +*+ [main] Initial commit
> 

this is the output of `git show-branch` [1] which has its own special display format. It's not often used these days.

The `!` are column markers, as is `*` for the current branch. You have three branches listed Then you have the `---` divider

Finally you has the single commit, showing which branches the commit is 'on'.

Be careful to discriminate between being 'on' a branch (at it's tip, by name); 'at' an oid (object id / hash); and `in` a branch (below its tip); etc.

[1] https://git-scm.com/docs/git-show-branch
Show 24 quoted lines
> the chunk of objects are on master and not main, and yet it shows
> nothing once checking out to master. 
> 
> the git-clone operation is not consistent either. It's a disaster.
> 
> One would think that by now with the more developed work put on to git, it'd
> be safe to assume the more sense there's on newer versions. But no. This
>  is the opposite actually. 
> 
> Now. If by any chance the git-branch operation were to return:
> 
>   main
> * master
> 
> after git-clone, then objects are indeed in place. That is. On master
> 
> but not if git-branch returns 
> 
>   main
> * master
>   origin/master
> 
> 
> 
Philip
Previous: Kristoffer HaugsbakkNext: Philip Oakley
Message 3 of 6 in “not robust inconsistent git 2.40.1 with HEAD -> master, origin/main, origin/HEAD, origin/master, main”
  1. CarlosMay 30, 2023
  2. Kristoffer HaugsbakkMay 31, 2023
  3. Philip OakleyMay 31, 2023
  4. Philip OakleyMay 31, 2023
  5. CarlosMay 31, 2023
  6. CarlosMay 31, 2023

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.