Skip to content

Instantly share code, notes, and snippets.

@zoepage
Created June 11, 2018 18:36
Show Gist options
  • Save zoepage/2af15a54aa05849974941d76aceb5145 to your computer and use it in GitHub Desktop.
Save zoepage/2af15a54aa05849974941d76aceb5145 to your computer and use it in GitHub Desktop.
git workflow for PRs from forked repos within your team
You work a lot with PRs from forked repos within your team?
My workflow for this:
Create a remote url with the name of the person as identifier like below:
$ git remote -v
julien https://github.com/julienw/perf.html.git
main https://github.com/devtools-html/perf.html.git
mstange https://github.com/mstange/perf.html.git
zoepage https://github.com/zoepage/perf.html.git
Use your fork as the main repo to review and fetch branches, you need to review per name.
How?
I usually create a branch with the name of the PR, e.g. `123-feature_v2` and pull the data in.
This way I also can work on changes, if I need to or can fork that branch.
$ git checkout -b 123-feature_v2
$ git pull julien 123-feature_v2
No need for different folders or other maybe messy hacks.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment