Last active
September 1, 2015 17:50
-
-
Save domenic/11371574 to your computer and use it in GitHub Desktop.
.bashrc with GitHub PR function
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pr () { | |
git fetch origin refs/pull/$1/head:refs/remotes/origin/pr/$1 --force | |
git checkout -b pr/$1 origin/pr/$1 | |
git rebase master | |
git checkout master | |
git merge pr/$1 --ff-only | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
For merging your own PRs, or in general any PR that uses a branch on the main repo instead of a fork, you can try:
Usage: