Junio C Hamano <gits...@pobox.com> wrote:

> Stephen Leake <stephen_le...@stephe-leake.org> writes:
> 
> >> Dropping the stash on a "git add" operation would be really, really
> >> weird...
> >
> > Why? That is when the merge conflicts are resolved, which is what
> > logically indicates that the stash is no longer needed,...
> 
> Not necessarily.  Imagine a case where you used stash to quickly
> save away a tangled mess that was not ready for a logically single
> commit and now you are in the process of creating the first commit
> by applying it piece-by-piece to create multiple resulting ones.
> After you commit the result, you would still want to keep the parts
> of that stashed change you did not include in the first commit so
> that you can go back, no?
> 
> You may run "git add", but that does not say anything about what you
> are going to use the rest of the stash for.  Not even "git commit"
> may be a good enough sign.

But we are only talking about the situation where you typed "git stash
pop", and this resulted in a merge conflict. Your intention was clearly
to drop the stash, it just wasn't dropped because of the conflict.
Dropping it automatically once the conflict is resolved would be nice.

I know it happened to me too that I forgot to drop a stash after
resolving conflicts, so I'd appreciate a feature that somehow does this
automatically for me.


-- 
Stefan Haller
Berlin, Germany
http://www.haller-berlin.de/
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to