#4 - Git - Stash

33
Rodrigo Branas – @rodrigobranas - http://www.agilecode.com.br #4 - Git - Stash

Transcript of #4 - Git - Stash

Page 1: #4 - Git - Stash

Rodrigo Branas – @rodrigobranas - http://www.agilecode.com.br

#4 - Git - Stash

Page 2: #4 - Git - Stash

Rodrigo [email protected]

http://www.agilecode.com.br

• Arquiteto de Software na Gennera • Professor na Agile Code • Autor na Java Magazine e PacktPub • Palestrante

Page 3: #4 - Git - Stash

http://www.youtube.com/rodrigobranas

Page 4: #4 - Git - Stash

Stash é uma área, onde é possível armazenar o código existente na

staging area, sem a necessidade de realizar um commit, permitindo mudar

de branch de forma limpa e organizada.

Page 5: #4 - Git - Stash

git checkout -b feature4

Page 6: #4 - Git - Stash
Page 7: #4 - Git - Stash

echo h > h.txt git add -A git status

Page 8: #4 - Git - Stash
Page 9: #4 - Git - Stash

git stash save "h.txt"

Page 10: #4 - Git - Stash
Page 11: #4 - Git - Stash

git status

Page 12: #4 - Git - Stash
Page 13: #4 - Git - Stash

git stash list

Page 14: #4 - Git - Stash
Page 15: #4 - Git - Stash

git stash apply stash@{0}

Page 16: #4 - Git - Stash
Page 17: #4 - Git - Stash

git stash list

Page 18: #4 - Git - Stash
Page 19: #4 - Git - Stash

git stash drop stash@{0}

Page 20: #4 - Git - Stash
Page 21: #4 - Git - Stash

git stash save "h.txt"

Page 22: #4 - Git - Stash
Page 23: #4 - Git - Stash

git status

Page 24: #4 - Git - Stash
Page 25: #4 - Git - Stash

git stash pop

Page 26: #4 - Git - Stash
Page 27: #4 - Git - Stash

git stash list

Page 28: #4 - Git - Stash
Page 29: #4 - Git - Stash

git stash save "h.txt"

Page 30: #4 - Git - Stash
Page 31: #4 - Git - Stash

git stash branch feature5

Page 32: #4 - Git - Stash
Page 33: #4 - Git - Stash

Rodrigo Branas

Site: http://www.agilecode.com.br Twitter: @rodrigobranas Facebook: http://www.facebook.com/canalrodrigobranas SlideShare: http://www.slideshare.com/rodrigobranas YouTube: http://www.youtube.com/rodrigobranas LinkedIn: http://br.linkedin.com/in/rodrigobranas +Plus: https://plus.google.com/+RodrigoBranas GitHub: http://www.github.com/rodrigobranas