GitHub Pages "Normal" Setup for User & Organization Pages
Let’s say your GitHub username is “alice”. If you create a GitHub repository named alice.github.com, commit a file named index.html into the master branch, and push it to GitHub, then this file will be automatically published to http://alice.github.com/... The same works for organizations.
Read more here: http://pages.github.com/
However... the downside of this is that anyone that forks this repo won't get it as a GitHub Pages repo when they are working on it... because they have a different GitHub "username" (or "organisation name").
So the trick is to not use a
master branch as the documentation tells you... rather, use a
gh-pages branch, as you would for your other "Project Pages".
- Create a New Repository on GitHub (don't follow any of the suggested setup instructions).
git branch -m master gh-pages<- renames the "master" branch to "gh-pages"
echo "<h1>Hello Alice</h1>" > index.html
git add index.html
- `git commit -m "initial commit"
- `git remote add origin email@example.com:alice/alice.github.com.git
git push -u origin gh-pages
This process is most likely most useful for Organization Pages...
I'm personally using it for my "viewsource" organization... which is an open source GitHub Pages hosted CDN.