mirror of
https://github.com/encounter/react-add-to-calendar.git
synced 2026-07-10 21:18:44 -07:00
26 lines
481 B
Bash
Executable File
26 lines
481 B
Bash
Executable File
#!/usr/bin/env bash
|
|
|
|
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
|
|
|
npm run build
|
|
|
|
mkdir -p tmp
|
|
|
|
if [ ! -d "tmp/gh-pages" ]; then
|
|
git clone git@github.com:jasonsalzman/react-add-to-calendar.git --branch gh-pages --single-branch tmp/gh-pages
|
|
fi
|
|
|
|
cd tmp/gh-pages
|
|
|
|
git pull
|
|
|
|
find . -maxdepth 1 ! -name '.git' ! -name '.' -exec rm -r {} \;
|
|
|
|
cp -r $DIR/{bundle.js,index.html,style.css,images} ./
|
|
|
|
git add --all
|
|
|
|
git commit -m "Publish new docs (automated commit)"
|
|
|
|
git push
|