Skip to content

Instantly share code, notes, and snippets.

@ngekoding
Forked from tunjos/gh-pages.md
Created August 22, 2021 01:29
Show Gist options
  • Save ngekoding/3848e2cb08a72aa1a8f9b679d051291d to your computer and use it in GitHub Desktop.
Save ngekoding/3848e2cb08a72aa1a8f9b679d051291d to your computer and use it in GitHub Desktop.
Creating a clean gh-pages branch

Creating a clean gh-pages branch

cd /path/to/repo-name
git checkout --orphan gh-pages
git rm -rf .
echo "My GitHub Page" > index.html
git add .
git commit -a -m "Add index.html"
git push origin gh-pages
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment