Search code examples
gitgithubgit-branchgithub-pages

Github Pages: This branch is even with gh-pages


I wanted to host a little web app that I wrote on github.io. So I've created a new orphan branch and called it gh-pages (it's essentially the same as my master branch). I made all the contributions and pushed it on Github. It works perfectly just as I have expected it.

The only thing that's weird is, that when I enter the gh-pages branch on Github it shows me a message that says: This branch is even with gh-pages. Did i made some misconseption here or is it normal and can't be changed?

You can see that branch and the message here: My Github Repository with the error (my site that showed the error, before I fixed it).


Solution

  • Well I've found a ressource finally and it says, that if your project hosted on Github is a website, instead of the master branch, you should simply call your main branch gh-pages. I think this is the most simple and logic way to do it and the message "This branch is even with gh-pages" is gone now, while everything is still working perfectly. Doing it this way helps me to push changes, too, because I can simply commit them to gh-pages instead of thinking about adding a change to both the master and my gh-pages branch.