I'm experimenting with github fork-and-pull model playing a role of maintainer (full access to golden repo) and a role of contributor (who contributes by forking and creating a pull request).
GitHub has clear directions for the maintainer on how to create a local branch from pull request in order to review the code locally (i.e. build/test/etc): From your project repo:
git checkout -b pr-review-branch-name master git pull [fork-url-from-pull-request] So far so good. As maintainer, I comment on the PR, and ask for some additional work. The contributor goes ahead and makes the requested changes, pushes them up to his fork on the server (and updates the pull request message board)..
My question: as Maintainer, do I need to create a new branch as described above to pull the updated code in the pull request? Or is there a way for me to update the branch I already created above?
Update: here are my exact commands (with identity removed):
$ /c/ws/demo/maintainer $ git clone https://server.xyz.com/PoCs/fork-and-pull-test.git Cloning into 'fork-and-pull-test'... Checking connectivity... done. $ /c/ws/demo/maintainer $ cd fork-and-pull-test/ $ /c/ws/demo/maintainer/fork-and-pull-test (master) $ git checkout -b pr-review-branch-name master Switched to a new branch 'pr-review-branch-name' $ /c/ws/demo/maintainer/fork-and-pull-test (pr-review-branch-name) $ git pull https://server.xyz.com/forker/fork-and-pull-test.git master ... From https://server.xyz.com/forker/fork-and-pull-test * branch master -> FETCH_HEAD Updating 57e8399..96cada4 Fast-forward .. $ /c/ws/demo/maintainer/fork-and-pull-test (pr-review-branch-name) $ git status On branch pr-review-branch-name nothing to commit, working directory clean $ git remote -v origin https://server.xyz.com/PoCs/fork-and-pull-test.git (fetch) origin https://server.xyz.com/PoCs/fork-and-pull-test.git (push)