Github downstream pull request?

倖福魔咒の 提交于 2020-01-11 04:54:07

问题


I have a project up on github, which an organization on github has forked. Can i push my code downstream to the organization's fork? I tried doing it, but was not able to.

I would like to know if i can send a pull request downstream?


回答1:


GitHub does allow this, and it's actually pretty easy to do, although I didn't find it very clearly-documented.

The short of it, is that when you navigate on Pull Requests > New Pull Request from the GitHub UI, you get taken to the "Compare" page. In the drop down to the left you can select your own branches, OR you can type in a branch on another user's repo (including downstream, or peers) in the form "username:branchname". So (using names from GitHub's examples) if user hubot wanted to submit a Pull Request to downstream user octocat, they would enter "octocat:master" on the left and keep "hubot:master" on the right.

Once the names on the left and right are entered, you'll be presented with the option to "Click here to create a pull request from this comparison." Voila! Downstream pull request!




回答2:


You can fork their fork of your repository and add that in as another remote on your repo. Then you can send a pull request to them.h You may need to add another user and add a different .ssh/config entry to provide a different public key. Sounds cool! :)



来源:https://stackoverflow.com/questions/9098747/github-downstream-pull-request

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!