Created
April 29, 2018 03:59
-
-
Save tuttelikz/ebb42bc369da3ce3f2bc00e344a228ad to your computer and use it in GitHub Desktop.
This is a simple procedure how one can create gh-pages branch on newly created repository
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Github's web hosting looks for a branch called "gh-pages" | |
# Git by names the default branch "master" so we must rename | |
# it to "gh-pages" so that Github can find the website files. | |
# In terminal/cmd | |
############################################################# | |
mkdir YOUR_REPO.github.com | |
cd YOUR_REPO.github.com | |
echo "# hello Sanzhar" >> README.md | |
git init | |
git checkout -b gh-pages | |
git add README.md | |
git commit -m "first commit" | |
git remote add origin https://github.com/YOUR-USER/YOUR-REPO.git | |
git push origin gh-pages | |
############################################################# | |
# Now if you check on github you should only leave with gh-pages branch | |
Settings (Repo settings) --> Branches --> Default Branch --> gh-pages --> Update |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment