Adding to someone else’s pull request on a GitHub project that I do not own

后端 未结 3 576
孤城傲影
孤城傲影 2021-02-05 00:53

Is it possible for me to add commits to someone else’s pull request on a repository where I am not the owner?

e.g.

User A owns Project X.

User B

3条回答
  •  后悔当初
    2021-02-05 01:25

    You can check out the branch and re-submit a modified PR (giving credit to the original, preferably).

    You can also issue a PR to the PR author:

    git remote add userb https://github.com/userb/name.git
    git fetch userb
    git checkout featurebranch
    [change and commit]
    git push userc featurebranch
    

    When you create a PR, GitHub lets you choose the base branch - so you can choose the fork and - if you want to - request changes to the PR.

提交回复
热议问题