Skip to content

Instantly share code, notes, and snippets.

@mhkeller
Created December 10, 2012 02:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mhkeller/4248002 to your computer and use it in GitHub Desktop.
Save mhkeller/4248002 to your computer and use it in GitHub Desktop.
Creating gh-pages from master branch
$ cd repo
$ git checkout --orphan gh-pages
# Creates our branch, without any parents (it's an orphan!)
# Switched to a new branch 'gh-pages'
git rm -rf .
# Remove all files from the old working tree
# rm '.gitignore'
$ git merge master
$ git push origin gh-pages
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment