Last active
July 6, 2018 05:42
-
-
Save anupkrbid/d5c6d12390c45350e07bfe6ea13ab05f to your computer and use it in GitHub Desktop.
Deploying ignored dist folder to GitHub Pages. Commit this script and call it after having built your dist.
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
#!/bin/sh | |
git commit -am "Save uncommited changes (WIP)" | |
git branch --delete --force gh-pages | |
git checkout --orphan gh-pages | |
git add -f dist | |
git commit -m "Rebuild GitHub pages" | |
git filter-branch -f --prune-empty --subdirectory-filter dist && git push -f origin gh-pages && git checkout - |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment