Skip to content

Instantly share code, notes, and snippets.

@cboettig
Last active November 28, 2016 22:51
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save cboettig/86a97437e74cd1bb128280a967570a18 to your computer and use it in GitHub Desktop.
Save cboettig/86a97437e74cd1bb128280a967570a18 to your computer and use it in GitHub Desktop.
#!/bin/bash
set -e
if [ -e ".git/shallow"] then
git config user.name 'Circle CI' && \
git config user.email 'bot@circleci.com'
git fetch --unshallow
git add docs/ && \
git commit -m 'site built on circle ci [ci skip]'
STATUS=`git push https://${CIRCLE_USERNAME}:${GH_TOKEN}@github.com/${CIRCLE_PROJECT_USERNAME}/${CIRCLE_PROJECT_REPONAME} master`
else
git add docs/ && \
git commit -m 'site built locally[ci skip]' &&
git push
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment