# Can not `git stash push -- .`

1 messages from 2023-08-29 to 2023-08-29. Participants: Eugen Konkov.
Thread: https://gitlist.dev/t/60168

## Eugen Konkov, 2023-08-29 19:11

Subject: Can not `git stash push -- .`
Message-ID: <CAHKPvkYtC88pEfACTXKM3a2CkbtMRjne9ZmAtF_+3K0KFZDXKw@mail.gmail.com>
URL: https://gitlist.dev/e/CAHKPvkYtC88pEfACTXKM3a2CkbtMRjne9ZmAtF_%2B3K0KFZDXKw%40mail.gmail.com

```
I tried to stash staged files with the command above, but got an
error. I even change directory to the top level (where .git is
located) and try to provide pathspec. Same result :(
ˋˋˋ
$ git stash push -S -m "core -> ubuntu Migration" -- tools/ec2.tf
tools/init.conf
Saved working directory and index state On branch/xxx: core -> ubuntu Migration
error: patch failed: state.d/terraform.tfstate.backup:2
error: state.d/terraform.tfstate.backup: patch does not apply
Cannot remove worktree changes
ˋˋˋ

Is there a way to stash only selected staged files from current
subdirectory, eg. `git diff --staged .`

Thank you.

```
