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

Re: [PATCH] checkout -d: explicitly detach HEAD even when switching to the tip of a branch

From
Jakub Narebski <jnareb@gmail.com>
Date
Mar 31, 2007, 00:11 UTC
Message-ID
<euk8ps$vu1$1@sea.gmane.org>
In-Reply-To
<7vr6r879zp.fsf@assigned-by-dhcp.cox.net>
Junio C Hamano wrote:
Show 7 quoted lines
> You cannot currently checkout the tip of an existing branch
> without moving to the branch.
> 
> This allows you to detach your HEAD and place it at such a
> commit, with:
> 
>     $ git checkout -d master
What about
      $ git checkout master^0
trick to force detaching?
-- 
Jakub Narebski
Warsaw, Poland
ShadeHawk on #git
Previous: Xavier MaillardNext: Xavier Maillard
Message 5 of 8 in “checkout -d: explicitly detach HEAD even when switching to the tip of a branch”
  1. checkout -d: explicitly detach HEAD even when switching to the tip of a branchJunio C Hamano, Mar 29, 2007
  2. Xavier MaillardMar 29, 2007
  3. Alex RiesenMar 29, 2007
  4. Xavier MaillardMar 29, 2007
  5. Jakub NarebskiMar 31, 2007
  6. Xavier MaillardMar 31, 2007
  7. Junio C HamanoApr 4, 2007
  8. Linus TorvaldsApr 4, 2007

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.