Home > Net >  Unable to fork personal github repository
Unable to fork personal github repository

Time:11-12

I have a github repository in my personal git account that I want to fork. It is a private git repo and only I can access it. But the Fork button at the top right of the page is greyed out and I cannot find the option to enable it in settings.

According to the enter image description here

CodePudding user response:

1.In the top right corner of GitHub.com, click your profile photo, then click Your organizations.

enter image description here

2.Next to the organization, click Settings. enter image description here

3.In the left sidebar, click Member privileges. enter image description here

4.Under "Repository forking", select Allow forking of private repositories or Allow forking of private and internal repositories. enter image description here

5.Click Save

or

if there is no organization linked to your account then try to lfollow these steps:-

 1. clone the private repository
 2. make a branch
 3. work on the branch
 4. push the branch to the private repository
 5. goto GitHub and create a pull request from the branch on the private repository
 6. someone else reviews the the pull request and decides to merge it with master on GitHub
 7. delete the branch unless there was a problem and it was not merged then go back to #3

CodePudding user response:

The fork option is not available within the settings, as your repo is private and not hosted by an organization (instead your personal account). According to my information, you can not fork your own repository, therefore your fork button is grayed out, because as you have mentioned your personal account is not part of any kind of organization which can be selected as the target hosting account of the fork.

I have found this gist which will maybe help you to "fork" it manually: https://gist.github.com/0xjac/85097472043b697ab57ba1b1c7530274

  • Related