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

Re: use of temporary refs in resolve

From
CMCatalin Marinas <catalin.marinas@gmail.com>
Date
Aug 8, 2005, 08:50 UTC
Message-ID
<tnxk6iwx161.fsf@arm.com>
In-Reply-To
<7v3bplwmzg.fsf@assigned-by-dhcp.cox.net>
Junio C Hamano <junkio@cox.net> wrote:
Show 16 quoted lines
> Here is my understanding of various "temporary heads" left
> directly underneath $GIT_DIR:
>
>     HEAD      : updated only after successful auto merge.
>
>     ORIG_HEAD : records the head value before resolve started.
>                 if automerge fails, this is the same as HEAD,
>                 but after successful automerge, this can be used
>                 to see what the previous head was.  This is the
>                 first parent of the resulting commit.
>
>     MERGE_HEAD: present if auto merge is unsuccessful and
> 		records the other head being merged.
>
>     LAST_MERGE: present if merge is unsuccessful or impossible and
> 		records the other head being merged.

Is FETCH_HEAD going to be preserved by the git-fetch-script operation? It should be, unless, git-pull-script removes it or it is changed to do the fetch as well.

In a repository managed with StGIT (i.e. updated with 'stg pull'), the base of the stack is always the same with FETCH_HEAD and StGIT uses this file. I also find it quite useful for:

  gitk ORIG_HEAD..FETCH_HEAD

to only see the remote commits since the local StGIT patches are always seen as commits on top of the FETCH_HEAD. It's also useful for people using 'git rebase'.

-- 
Catalin
Previous: Linus TorvaldsNext: Junio C Hamano
Message 5 of 10 in “use of temporary refs in resolve”
  1. Junio C HamanoAug 7, 2005
  2. Linus TorvaldsAug 7, 2005
  3. Junio C HamanoAug 7, 2005
  4. Linus TorvaldsAug 7, 2005
  5. Catalin MarinasAug 8, 2005
  6. Junio C HamanoAug 8, 2005
  7. Catalin MarinasAug 8, 2005
  8. Junio C HamanoAug 9, 2005
  9. Catalin MarinasAug 9, 2005
  10. Junio C HamanoAug 9, 2005

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.