Re: [BUG?] Detaching head at checked out point does not work.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Jan Hudec <bulb@xxxxxx> writes:

> Hello,
>
> I can correctly detach head by saying:
>
>   git checkout master^0
>
> (or git checkout master^{} or git checkout refs/heads/master), but NONE of
> these work, if I currently have master checked out. Shouldn't it detach
> anyway?

Yes, and it does as far as I know.

Do you have 3e0318a3?

commit 3e0318a3613ae8e89dcb1fc39d909145e64287b9
Author: Junio C Hamano <junkio@xxxxxxx>
Date:   Thu Mar 29 01:02:50 2007 -0700

    checkout: allow detaching to HEAD even when switching to the tip of a branch
    
    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 master^0
    
    Signed-off-by: Junio C Hamano <junkio@xxxxxxx>

-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux