PairDrop/travis-runner.sh

19 lines
632 B
Bash
Raw Normal View History

2015-12-18 16:50:36 +01:00
#!/bin/bash
set -o pipefail
if [ "$TRAVIS_BRANCH" = "master" ] && [ "$TRAVIS_PULL_REQUEST" = "false" ]
then
git config --global user.email "samccone@gmail.com" && \
git config --global user.name "auto deployer" && \
echo "Deploying!" && \
sed -i.tmp "s/\/\/ app.baseUrl = '\/polymer-starter-kit/app.baseUrl = '\/polymer-starter-kit/" app/scripts/app.js && \
rm app/scripts/app.js.tmp && \
bower i && \
gulp build-deploy-gh-pages && \
sed -i.tmp "s/app.baseUrl = '\/polymer-starter-kit/\/\/ app.baseUrl = '\/polymer-starter-kit/" app/scripts/app.js && \
rm app/scripts/app.js.tmp
else
npm run lint
npm test
fi