Setting up git: Difference between revisions
adds quick local PR checkout guide
imported>Jordie0608 (NT -> TG) |
imported>Cheridan (adds quick local PR checkout guide) |
||
Line 103: | Line 103: | ||
* You're done! | * You're done! | ||
== Step 12 - Checking Out Github PRs Locally (Optional) == | |||
*'''This is a must for maintainers who need to easily test other people's code!''' | |||
*Locate the section for your github remote in the .git/config file. It looks like this: | |||
:[remote "upstream"] | |||
[ | ::fetch = +refs/heads/*:refs/remotes/upstream/* | ||
::url = https://github.com/tgstation/-tg-station.git | |||
*Now edit it to look like this: | |||
:[remote "upstream"] | |||
::fetch = +refs/heads/*:refs/remotes/upstream/* | |||
::url = https://github.com/tgstation/-tg-station.git | |||
::fetch = +refs/pull/*/head:refs/remotes/upstream/pr/* | |||
*Fetch from the upstream remote. | |||
*To check out a particular pull request, use Switch/Checkout and select the branch from the drop-down list. |