Skip to content

Instantly share code, notes, and snippets.

@forelabs
Created September 25, 2019 08:34
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 forelabs/c44adaf53aeac7f3b1879822960cf1ea to your computer and use it in GitHub Desktop.
Save forelabs/c44adaf53aeac7f3b1879822960cf1ea to your computer and use it in GitHub Desktop.
branch rebase master
function grmaster() {
b=$(git branch | sed -n '/\* /s///p')
git checkout master
git pull --rebase
git checkout $b
git rebase master
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment