Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SHELL

git stash

git stash save "Stash message for reference"  #To add changes to stash stack
git stash list					 		 	  #Shows all the stashed change list
git stash clear 							  #clears stash list
To apply the stash changes :
a) git stash apply stash @{n}
	you can reapply the changes to your working copy and keep them in your stash with git stash apply
b) git stash pop stash@{n} 
 -> Popping your stash removes the changes from your stash and reapplies them to your working copy
	n - stash number to be applied  		  #Applying stash changes
git stash -u     -u optiontells git stash to also stash your untracked files
git stash drop stash@{1}					  #Cleaning up your stash
Source by www.atlassian.com #
 
PREVIOUS NEXT
Tagged: #git #stash
ADD COMMENT
Topic
Name
8+5 =