You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
#!/bin/bash
# logecho "..."echo "Updating Github.io page"echo "..."# Generate index.html and /temp assetts for GH Pages branchgrunt build-gh-pages# Create temporary copy of index filecp index.html index-temp.html# Checkout to `gh-pages` branchgit checkout -B gh-pages origin/gh-pagesgit pull -r origin gh-pages# Replace current files with temporary filesmv index-temp.html index.htmlcp node_modules/bootstrap/dist/css/bootstrap.min.css css/bootstrap.min.cssmv temp/bootstrap-slider.css css/bootstrap-slider.cssmv temp/bootstrap-slider.js js/bootstrap-slider.js# Remove /temp directoryrm -rf temp# Stage new files for commitgit add index.html css/bootstrap-slider.css js/bootstrap-slider.js css/bootstrap.min.css# Create commit with new filesgit commit -m "updates"# Push new source code to gh-pages branchgit push origin gh-pages:gh-pages -f# Switch back to master branchgit checkout master# logecho "..."echo "Github.io page updated"echo "..."
|