diff --git a/.travis.yml b/.travis.yml index 006a88417..9cc7a9374 100644 --- a/.travis.yml +++ b/.travis.yml @@ -3,6 +3,11 @@ node_js: - "4.4.7" before_install: - npm install -g grunt-cli +- git config --global user.name "Travis CI" +- git config --global user.email "travis@travis-ci.org" +- git remote add origin_ssh git@github.com:alphagov/govuk_elements.git +- 'if [ "$TRAVIS_PULL_REQUEST_BRANCH" = "master" ]; then openssl aes-256-cbc -K $encrypted_85ebe8034b89_key -iv $encrypted_85ebe8034b89_iv -in .travis/govuk_elements.enc -out ~/.ssh/id_rsa -d && chmod 600 ~/.ssh/id_rsa; fi' +- # This openssl command was generated automatically by `travis encrypt-file`, see `.travis/README.md` for more details install: - npm install script: @@ -11,11 +16,6 @@ notifications: email: false before_deploy: - test $TRAVIS_TEST_RESULT = 0 -- git config --global user.name "Travis CI" -- git config --global user.email "travis@travis-ci.org" -- git remote add origin_ssh git@github.com:alphagov/govuk_elements.git -# This openssl command was generated automatically by `travis encrypt-file`, see `.travis/README.md` for more details -- openssl aes-256-cbc -K $encrypted_85ebe8034b89_key -iv $encrypted_85ebe8034b89_iv -in .travis/govuk_elements.enc -out ~/.ssh/id_rsa -d && chmod 600 ~/.ssh/id_rsa deploy: - provider: script script: './push-version-tag.sh'