Can I arrange repositories into folders on Github?

2019-01-13 04:44发布

I am new to git and what I am doing now is to upload all my recent projects as repositories to github. There are a lot of different projects like webdesign, wordpress themes and different types of applications. And some of these also belong to bigger projects because they were about testing some stuff as a different application.

The problem is that I have a confusing amount of repositories online now. How can I group related github repositories in a folder structure? Is there a feature providing any ability to order and structure or even tag repositories on github?

3条回答
够拽才男人
2楼-- · 2019-01-13 05:24

On GitHub itself, you cannot group your repos by "folder", unless you create organizations.
See SublimeText, for instance, as a group of all sublimeText packages repos.

But that won't support a nested folder organization.

For now (June 2017), that only support a nested team organization structure.


Another solution is for you to define repositories which reference other repos, declared as submodules.

That way, when you are cloning one of the repos (which references other repos), called "parent repos", they will be cloned in their own directory, with a sub-directory per submodules.

It won't be visually apparent on your GitHub account itself (as it will still contains a large list of repos, even larger with the parent repos), but by cloning one parent repo, you will get back all its associated submodules in it.


The issue 302 mentioned in the comments by AnneTheAgile in 2014 just references now (Nov. 2018) tbnorth/github_repo_tags

The small python program in this repository uses the GitHub API to get a list of your repos. and add their name, description, and URL, to a new repo., by default called repo_tags. Initially each “issue” is tagged unclassified, but you can tag them as you please, using regular issue tagging.

When re-run, repo_tags.py only creates issues for repos. that weren't already covered by an issue.

查看更多
我只想做你的唯一
3楼-- · 2019-01-13 05:26

I use Organizations to arrange repos. This allows for clean delineation and clear organization, ripe for sharing if needed. For example:

My Organizations

  • Jmr-iOS (iOS repos)
  • Jmr-Work (Work repos)
  • User Acct (Pers repos)

All organization repos are public though unless you upgrade to a developer account ($7/mo)

查看更多
可以哭但决不认输i
4楼-- · 2019-01-13 05:50

This is not an answer so much as a heads up.

One recent side effect of structuring utilizing organizations has come to light due to the following announcement of free private repos for users: https://blog.github.com/2019-01-07-new-year-new-github/

Organization private repos are still not free. So using organizations to separate repos will result in your organization's inability to utilize free private repos, if that's something you need.

查看更多
登录 后发表回答