2017-09-28 17:35:22 +00:00
|
|
|
#!/bin/sh
|
|
|
|
|
|
|
|
repo="$TRAVIS_REPO_SLUG"
|
|
|
|
token="$GH_TOKEN"
|
|
|
|
commit=$(git rev-parse --short HEAD)
|
|
|
|
msg="Documentation for $repo@$commit"
|
|
|
|
|
2017-10-01 18:28:35 +00:00
|
|
|
# add a homepage
|
|
|
|
cp ./doc_index.html ./target/doc/index.html
|
|
|
|
|
2017-09-28 17:35:22 +00:00
|
|
|
git clone https://github.com/davisp/ghp-import
|
|
|
|
./ghp-import/ghp_import.py -n -m "$msg" target/doc
|
|
|
|
# pipe output to /dev/null to avoid printing our token in travis log
|
|
|
|
git push -fq "https://$token@github.com/$repo.git" "gh-pages" > /dev/null
|