Sometimes a pull request on GitHub.com needs some work before it can be merged into the project but you don’t want to force the required work on the pull requests original author. You’re allowed to make changes to the pull request if they are opened to a repository you have push access to, the fork is user-owned, the user has granted the required permissions and there aren’t any branch restrictions that will prevent committing.
-
Add an additional remote for the forked project, e.g.
git remote add roaldnefs git@github.com:roaldnefs/salt-lint.git
. -
Fetch all branches using the
git fetch roaldnefs
command. -
Switch to the branch in the forked project, e.g.
git checkout my-branch
. -
You can now do anything with the branch. You can rebase it, run in locally or add new commits.
-
After you’ve made the necessary changes you simply push the changes using the
git push
command.
Your changes should now be reflected in the original pull request on GitHub.com.