Re: stash push/pop unstages files?
- From
Chris Torek <chris.torek@gmail.com>
- Date
- Sep 5, 2021, 19:19 UTC
- Message-ID
- <CAPx1GvfEW4rVHjxmmNmAEOVYFgeehbmDQouCWWZx=aiiDy89Vg@mail.gmail.com>
- In-Reply-To
- <5f09cba9-b7dc-d7b6-1d3f-e7fb8ca28c6c@rawbw.com>
On Sun, Sep 5, 2021 at 12:02 PM Yuri <yuri@rawbw.com> wrote:
> Why 'stash push' and 'stash pop' are asymmetric in what they do by default? > Wouldn't it make more sense to make 'stash pop' precisely revert what > 'stash push' does, and have an option '--no-index' instead?
If you ask me, yes, it would—but it would make even *more* sense if `git stash` didn't bother saving the index at all without `--index`, and just errored out if the index and working tree didn't match. But I didn't write `git stash`.
My personal recommendation is: never (or hardly ever) use it. Just make a commit.
Chris