github: transfer ownership and fork

拟墨画扇 提交于 2020-05-26 09:19:22

问题


I've transfered ownership of one of my github repositories (rdmuller/docToolchain) to an organisation (docToolchain/docToolchain). So far, so good. All old URLs are redirected to the new location. Perfect.

But how do I now fork this repository? I fear that, if I fork it, a fork with the name of the old repository (rdmueller/docToolchain) will be created and the redirect will be broken this way...

how can I avoid this?


回答1:


So, I guess I found a workaround.

suppose you have a repository

user1/repo1

You now want to transfer ownership to org1 and create a fork of it in your account user1.

The problem is that, if you create this fork directly, there will be again a repo called user1/repo1 and github is not able to redirect URLs to the old repository to org1/repo1

Solution:

  • transfer ownership from user1/repo1 to org1/repo1
  • create a temporary organisation org2
  • fork org1/repo1 to org2/repo1
  • rename org2/repo1 to something like org2/repo1-fork
  • transfer ownership from org2/repo1-fork to user1/repo1-fork

this seems to do the trick.




回答2:


Since May 2020, Ben Balter (Senior Product Manager working on Community and Safety at @GitHub) mentions in his tweet:

We're beta testing a new GitHub feature that allows you to invite someone to manage your open source projects in the event that you are unable able to do so yourself.

If you'd like early access, reply or DM with your GitHub handle and I can add you.

See "Maintaining ownership continuity of your user account's repositories"

You can invite someone to manage your user owned repositories if you are not able to.

We recommend inviting another GitHub user to be your successor, to manage your user owned repositories if you cannot. As a successor, they will have permission to:

  • Archive your public repositories.
  • Transfer your public repositories to their own user owned account.
  • Transfer your public repositories to an organization where they can create repositories.


来源:https://stackoverflow.com/questions/46434127/github-transfer-ownership-and-fork

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