Skip to content

Instantly share code, notes, and snippets.

@bunnymatic
Created January 5, 2011 18:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bunnymatic/766717 to your computer and use it in GitHub Desktop.
Save bunnymatic/766717 to your computer and use it in GitHub Desktop.
This bash function, when run from your current branch will jump to master, pull and jump back to your current branch, leaving you all ready to rebase master and then merge branch into master. Add it to your .profile and roll on.
rebase_prep() {
git checkout master && git pull && git checkout -
}
@bunnymatic
Copy link
Author

This goes hand in hand with Jared's method for integrating feature branches in git. http://blog.carbonfive.com/2010/11/01/integrating-topic-branches-in-git/

@bunnymatic
Copy link
Author

as it turns out, the git alias is much nicer to work with. https://gist.github.com/766967

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment