Re: [BUG] - "git commit --amend" commits, when exiting the editor with no changes written
- From
Matthieu Moy <matthieu.moy@grenoble-inp.fr>
- Date
- Feb 3, 2010, 07:34 UTC
- Message-ID
- <vpqaavqkc1s.fsf@bauges.imag.fr>
- In-Reply-To
- <20100203015947.GA4280@neumann>
SZEDER Gábor <szeder@ira.uka.de> writes:
> No. In case of rebase -i, exiting the editor is being explicit in > "the todo file now contains what you should do, so do it". And if the > todo file happens to be empty, then there is nothing to do, so do > nothing.
It's not true. The todolist is the list of things to do after you rewind your branch to the destination branch. Strictly speaking, an empty todolist should mean to drop all the patches (like a todolist with just one line would mean to drop all the others). But a user never wants to do that (otherwise, "git reset" would be the right command), so "git rebase -i" considers it as a special case.
My 2 cents,
-- Matthieu Moy http://www-verimag.imag.fr/~moy/