Re: Re: [PATCH] Docs: git checkout --orphan: `root commit' and `branch head'

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

 



On Tue, Sep 27, 2011 at 23:35, Jeff King <peff@xxxxxxxx> wrote:
> On Tue, Sep 27, 2011 at 11:28:14PM +0000, Michael Witten wrote:
>
>>   With "git commit --no-parent", you would be altering the current
>>   branch head, which means you are potentially leaving as a dangling
>>   commit the commit to which that branch head originally pointed.
>>   I.e., it is about as dangerous as "git reset --hard <new_root_commit>",
>>   something for which we do NOT provide any protection.
>
> Didn't I already mention that example? And then say that I think the
> lack of protection there has been the source of a lot of confusion and
> hardship?

Sorry, I suppose you did already mention that, but:

  * I missed it because of the footnote.
  * There is more pedantry to my text than just that.

> Repeating the problems of "git reset" does not seem like a good idea to
> me. Especially not with a command like "commit", which is usually very
> safe.

I think that "git reset" is confusing and dangerous for more
fundamental reasons: It's another one of git's bizarre, poorly
chosen abstractions on top of the working tree and index.
--
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]