joshlf
joshlf

Reputation: 23637

How do I include a GitHub repository in my <username>.github.io page?

I'm looking at this page for the game 2048: http://gabrielecirulli.github.io/2048/

The author has it hosted at his github.io domain, but the repository for the code is http://github.com/gabrielecirulli/2048. I'm wondering - how do I do something similar, hosting a repository that is not explicitly recognized by GitHub as a github page as part of my larger github page? So, for example, I have the repo http://github.com/joshlf13/joshlf13.github.io (it's not set up yet), and I also have a different repo that has code (html, js, etc) that I'd like to host in my github page, how do I do that? Thanks!

Edit:

I know that I could copy the sub-page code into the main github.io repo. I'd prefer to not copy code (among other things, it would mean that I could push to the original repo and the code would automatically be updated on the site). I could imagine using git submodules for this, but I'm skeptical that that'd work given that the git server doesn't actually store the submodule, but rather simply a reference to the submodule.

Upvotes: 0

Views: 261

Answers (1)

TimWolla
TimWolla

Reputation: 32711

github makes the gh-pages branch of each repository available under:

<username>.github.io/<repository>/

Additionally <username>.github.io is directly available under the subdomain.

Have a look at the “project site” tab of: http://pages.github.com/

Upvotes: 2

Related Questions