If you do a git stash -u, it will create a commit for you that includes staged, unstaged and untracked files, and it knows which files were staged and which ones weren't. If you wanted to keep the changes that were stashed as they were, you can issue a git stash apply immediately after (use apply to keep the stash, or pop to discard it after applying it).
Git never seizes to amaze me for its unlimited functionality.
For applying the stash, you need add --index as in: git stash apply --index. This will restore the index (staged/unstaged files) along with the file changes.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
It already is, in a way.
If you do a
git stash -u
, it will create a commit for you that includes staged, unstaged and untracked files, and it knows which files were staged and which ones weren't. If you wanted to keep the changes that were stashed as they were, you can issue agit stash apply
immediately after (useapply
to keep the stash, orpop
to discard it after applying it).This is amazing! Thank you!
Git never seizes to amaze me for its unlimited functionality.
For applying the stash, you need add
--index
as in:git stash apply --index
. This will restore the index (staged/unstaged files) along with the file changes.