Subject: Re: [PATCH] rebase: learn --discard subcommand

From: Michael Haggerty <[email-masked]>
Date: Mon, 30 May 2011 06:50:55 +0200

On 05/28/2011 08:51 PM, Junio C Hamano wrote:
> "git reset --hard" used to be such a command in simpler times. It removes
> MERGE_HEAD unconditionally, so that a confused user can start from scratch
> without having to worry about what was in progress. As a devil's advocate,
> I am wondering if it is a good idea to simply teach "reset --hard" to also
> remove any and all "sequence" cruft (.git/rebase-apply, .git/rebase-merge,
> CHERRY_PICK_HEAD; we might have others I do not recall offhand) and be
> done with it. It is a large hammer, but it is certainly the easiest to
> explain and the simplest to understand way to get out of any troubles.

If it would be desirable to separate the resetting of the working tree
from the resetting of any in-progress operation, perhaps "git reset
--abort" (by analogy with "git reset --abort" etc) would be a possible
spelling of the latter.  To reset any in-progress operations *and* reset
the working tree, on could use "git reset --hard --abort".

I strongly agree with another poster that it would be useful if "git
status" would print information about in-progress operations.

Michael

-- 
Michael Haggerty
[email-masked]
http://softwareswirl.blogspot.com/