Github: How do I add my own projects to an "organization" account?
Asked Answered
S

2

78

I have started collaborating on a series of projects with several developers on github, and we recently created an organization with it's own "organization" type account on github. I see that I can fork repositories of my collaborators into the organization account using the usual fork menu, but of course I cannot fork my own account.

What is the expected workflow to import my existing repositories into the organizational account? (I presume I could fork projects hosted by the other members, but not my own?)

Supremacist answered 16/11, 2011 at 19:40 Comment(2)
You can move a repo you own to an organization on which you have admin access: help.github.com/move-a-repoFlavia
The question says a project, not a repo. They're not the same thing. Transfering a repo is easy, transferring a project is turning into a pain.Tryma
A
66
  • Navigate to the Settings tab of your repository:

enter image description here

  • Scroll down to the Danger Zone and click Transfer:

enter image description here

  • After reading the warnings, provide the name of the repository that you want to transfer and the specific organisation that the repository is going to be transferred to and click I understand, transfer this repository:

enter image description here

  • Done! You 'll then be notified that you action will take effect in a few minutes:

enter image description here

For more details, you can always refer to the official documentation.

Warning: once this is done, make sure you also update any local repository references using the following command git remote set-url origin <new-origin>.

Affected answered 24/1, 2016 at 23:15 Comment(1)
I believe that is good to mention that after this procedure, it's necessary to update any local repository changing the remote origin with something like ` git remote set-url origin <new-origin>`. This answer worked like a charm, but I spent some minutes before realizing that.Mister
T
16

In the updated github UI all you need to do is go to your project and click "Fork" and then it will ask you if you want to fork into an organization that you are an admin of.

Way simple, just not easy to find.

Tuff answered 31/7, 2014 at 16:56 Comment(2)
Forking is not the same as moving a repository. GitHub will mark it as a fork of the original repository rather than the official home of the repository.Weathered
I think this answer works better for COPYING a repo to an org not moving or transferring.Paleethnology

© 2022 - 2024 — McMap. All rights reserved.