Created
July 19, 2017 15:00
-
-
Save cooperka/c4e08cca33dbcacbb421a61c2df571a2 to your computer and use it in GitHub Desktop.
A one-time setup to fetch code directly from GitHub PRs, so you don't need to download their fork or figure out their branch name.
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
# One-time setup | |
git config --global --add remote.origin.fetch "+refs/heads/*:refs/remotes/origin/*" | |
git config --global --add remote.origin.fetch "+refs/pull/*/head:refs/remotes/origin/pr/*" # This is the important one | |
# Make sure there aren't duplicate configs | |
git config --global --list | |
# Checkout someone else's PR! | |
git fetch origin | |
git checkout pr/20 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment