Spotify.NET/push-ghpages.sh

23 lines
533 B
Bash
Raw Permalink Normal View History

#!/bin/bash
2015-02-24 19:00:21 +00:00
2015-02-24 19:17:13 +00:00
if [ "$TRAVIS_PULL_REQUEST" == "false" ]; then
2015-02-24 19:00:21 +00:00
2015-02-24 17:36:19 +00:00
echo Starting push to gh-pages...
mkdir deploy
cd deploy
git config --global user.email "johnny@johnnycrazy.de"
git config --global user.name "Travis-CI"
git clone --quiet --branch=gh-pages https://${GH_TOKEN}@github.com/JohnnyCrazy/SpotifyAPI-NET gh-pages > /dev/null
cd gh-pages
2015-02-24 18:30:02 +00:00
git rm -rf ./ 2> /dev/null
cp -Rf ../../site/* ./
2015-02-24 17:36:19 +00:00
git add -f .
git commit -m "Built mkdocs | Travis Build $TRAVIS_BUILD_NUMBER"
2015-02-24 17:36:19 +00:00
git push -fq origin gh-pages > /dev/null
2015-02-24 19:00:21 +00:00
echo -e "Done"
fi