Re: [PATCH] checkout: indicate when a detached head is checked out for a branch

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

 



Junio C Hamano venit, vidit, dixit 19.07.2014 00:18:
> Dennis Kaarsemaker <dennis@xxxxxxxxxxxxxxx> writes:
> 
>> My use case for this is checking out the same branch (or commit, so
>> already on a detached HEAD) in multiple different places to run
>> independent actions (e.g. make test with different compiler options, or
>> creating several different packages) and I would really appreciate it if
>> that would keep working.
> 
> I do not have any problem if multiple working trees have the same
> commit checked out on their own detached HEADs at all.  The "should
> error out" was solely for the case where the user asked not to detach
> but to obtain a state where a named branch is checked out.  In such
> a case, the command should not turn it into a detached HEAD, with or
> without a warning.

Exactly, all of that, plus:

* "git checkout --detach --to foo bar" could/should be a way to spell out
"git checkout --to foo bar^0".

* In the case of erroring out, "git checkout" could suggest one of the
above two commands.

Michael
--
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]