GitHub provides a special pulls remote "namespace" on the upstream repo, so you can add it as a fetch pattern to your .git/config like so:
[remote "upstream"]
url = https://github.com/neovim/neovim.git
fetch = +refs/heads/*:refs/remotes/upstream/*
fetch = +refs/pull/*/head:refs/pull/upstream/*
Then when you git fetch --all
, you will have ALL pull requests available in your local repo in the local pull/ namespace. To check out PR #42:
git checkout -b foo refs/pull/upstream/42