Skip to content

Instantly share code, notes, and snippets.

@ryanseys
Last active December 17, 2015 04:18
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ryanseys/5549172 to your computer and use it in GitHub Desktop.
Save ryanseys/5549172 to your computer and use it in GitHub Desktop.
Sync master & gh-pages by adding these 2 lines in your .git/config file
[remote "origin"]
fetch = +refs/heads/*:refs/remotes/origin/*
url = git@github.com:user/repo.git
# add the following 2 lines so $ git push pushes to both master & gh-pages
push = +refs/heads/master:refs/heads/gh-pages
push = +refs/heads/master:refs/heads/master
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment