Files
embbed-rust/ci/after-success.sh
Jorge Aparicio 4c004db265 add ci
2018-08-10 00:00:41 -05:00

18 lines
453 B
Bash

set -euxo pipefail
main() {
mkdir ghp-import
curl -Ls https://github.com/davisp/ghp-import/archive/master.tar.gz |
tar --strip-components 1 -C ghp-import -xz
./ghp-import/ghp_import.py book
# NOTE(+x) don't print $GH_TOKEN to the console!
set +x
git push -fq https://$GH_TOKEN@github.com/$TRAVIS_REPO_SLUG.git gh-pages && echo OK
}
if [ $TRAVIS_BRANCH = master ] && [ $TRAVIS_PULL_REQUEST = false ]; then
main
fi