Git Stash Command

Video loading...

Join Drupalize.Me to watch this video

Join today and gain instant access to our entire video library.

Log in Sign up
  • 0:06
    Now that we're working with multiple remote repositories,
  • 0:08
    we might want a way to temporarily preserve our work that's not quite ready for commit.
  • 0:13
    We can use git stash, git stash apply, and git stash pop to take care of this.
  • 0:19
    Here we are working away on our local repository.
  • 0:23
    As you can see with git status, we've been working on the file notes.txt.
  • 0:28
    In the meantime, Joe has been working away
  • 0:30
    and has pushed some changes to the remote repository on GitHub
  • 0:33
    that he wants me to take a look at right away.
  • 0:35
    Since this is a work in progress and I'm not quite ready to commit it yet,
  • 0:39
    we're going to use git stash to set our work aside temporarily
Loading ...

Git Stash Command

Loading...

This lesson takes a look at using the git stash commands to temporarily preserve your work when you need to incorporate other changes but aren't quite ready to fully commit them.

Additional resources: