What is git stash

Description: Use git stash when you want to record the current state of the working directory and the index, but want to go back to a clean working directory.


When to use: If you have done some changes to you existing git repository files then you don't need to perform git commit and then take a pull of other developers to work. Git stash is a saviour for the interrupted workflow scenario

How to Use/commands:

git stash save <message> or git stash(create new stash)

git stash list(it will git stash list)

git stash show -p <stash-id>(it will show stash contain by id)

git stash pop(it will take recent stash)

git stash pop <stash-id>(get specific stash by stash id)

git stash drop (drop latest stash)

git stash drop <stash-id>(drop specific stash)


Comments

Popular posts from this blog

How can I debug PHP cURL sessions?

Free icons

Where is the security section of google analytics? “Security Issues” section.