add travis

This commit is contained in:
Carl Pearson
2017-12-17 17:04:10 -06:00
parent 23a87eaffe
commit 94023c5350

15
.travis.yml Normal file
View File

@@ -0,0 +1,15 @@
after_success: |
if [ -n "$GITHUB_API_KEY" ]; then
cd "$TRAVIS_BUILD_DIR"
# This generates a `web` directory containing the website.
make web
cd web
git init
git checkout -b gh-pages
git add .
git -c user.name='travis' -c user.email='travis' commit -m init
# Make sure to make the output quiet, or else the API token will leak!
# This works because the API key can replace your password.
git push -f -q https://<me>:$GITHUB_API_KEY@github.com/<me>/<myrepo>-gh-pages gh-pages &2>/dev/null
cd "$TRAVIS_BUILD_DIR"
fi