What's the process for fetching GitHub pull requests using git?

Hey everyone, I’m trying to figure out how to grab a pull request from GitHub using git. I’ve seen some stuff about refs/pull but I’m not sure how to use it.

I added this line to my git config:

fetch = +refs/pull/*/head:refs/remotes/origin/pr/*

Then I ran git fetch but nothing happened. Am I missing a step? Does GitHub create these pull request refs automatically or do I need to set something up first?

I’m pretty new to working with pull requests this way, so any help would be awesome. Thanks!

hey there! i’ve dealt with this before. after adding that config line, try running git fetch origin. that should grab the PRs. if it still doesnt work, double check ur remote is set up right with git remote -v. hope that helps!