hub fork <new repo name>

Created on 22 Nov 2014  路  5Comments  路  Source: github/hub

It would be nice to be able to fork a repo with another name

git clone github/hub hub-custom
cd hub-custom
git fork hub-custom

This would result in a fork on my github that's named hub-custom

feature

Most helpful comment

I could see no one had requested the API change to help this feature along, so I created: https://github.community/t5/GitHub-API-Development-and/Add-support-for-rename-repository-when-creating-a-fork-from-API/m-p/44329#M3923

All 5 comments

Also if the git fork github/hub gets added then maybe git fork github/hub hub-custom could be useful

Hub uses octokit in the background. There's not a documented way to fork under another name, or rename repos that would allow this project to juggle them around. I don't think this is possible until the api supports that.

https://developer.github.com/v3/repos/forks/#create-a-fork

There's not a documented way to fork under another name, or rename repos that would allow this project to juggle them around.

The API does allow you to rename a repository:

https://developer.github.com/v3/repos/#edit

Here's the git script that I use for making forks. It does a rename of the fork. Hope it helps someone.
https://gist.github.com/grimm26/5f87575f84eda316a7786ffc2acd6f9f

I could see no one had requested the API change to help this feature along, so I created: https://github.community/t5/GitHub-API-Development-and/Add-support-for-rename-repository-when-creating-a-fork-from-API/m-p/44329#M3923

Was this page helpful?
0 / 5 - 0 ratings