ronsun
12/22/2018 - 6:16 AM

create gh-pages branch on github

How to create ph-pages for GitHub Pages on GitHub

ways to publish githubp pages

Configuring a publishing source for GitHub Pages

create gh-pages branch

git checkout --orphan gh-pages # create and checkout to an orphan branch
git reset . # reset
git clean -fxd # remove all files without .git, but I don't know why it works
echo 'Hello world' > index.html  # 新增一個 hello word 的 html 檔
git commit -m 'init'  # commit
git push -u origin gh-pages  # push