Is there a special reason why I cannot "finish a feature" (using git-flow) while my sandbox contains unstaged/non-commited changes?
You'll often want to do two things: change the commit message, or change the actual content of the commit by adding, removing and modifying files. error: cannot rebase: You have unstaged changes.
Cannot pull with rebase: You have unstaged changes. Please commit or stash them. Git stash command is kind of commit stored changes to temporary space and clean working copy. Then your working copy will be reverted to HEAD.It is a good place to store uncommitted changes.
For all unstaged files in current working directory use: git restore . That together with git switch replaces the overloaded git checkout (see here), and thus removes the argument disambiguation. If a file has both staged and unstaged changes, only the unstaged changes shown in git diff are reverted.
You can do the following:
git stash
to store your changes temporarilygit stash pop
to get the stashed changes back on top of your current working directoryIf you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With