9. GIT STASH AND GIT CLEAN COMMANDS Flashcards
GIT STASH COMMAND
Usage: git stash save
This command temporarily stores all the modified tracked files.
Stashing is a way of putting away code temporarily so that you can work on something else. This is the perfect thing to use when maybe your boss comes in and tells you that he needs a super important change, but you were already working on some new changes on the current branch that you were into. You essentially want to restore everything, but you want to not lose any of the changes that you’ve made.
GIT STASH LIST COMMAND
Usage: git stash list
This command lists all stashed changesets.
GIT STASH POP COMMAND
Usage: git stash pop
This command restores the most recently stashed files.
GIT CLEAN COMMAND
Usage: git-clean
Remove untracked files from the working tree.