Skip to content
This repository has been archived by the owner on Aug 18, 2019. It is now read-only.

Commit

Permalink
update travis build
Browse files Browse the repository at this point in the history
  • Loading branch information
olefebvre committed Nov 2, 2016
1 parent 115a3fc commit 926ecb1
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 18 deletions.
8 changes: 4 additions & 4 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,10 @@ branches:
- develop
script:
- "./build.sh"
env:
env:
global:
- ENCRYPTION_LABEL: "a75b2f1dfc5f"
- COMMIT_AUTHOR_EMAIL: "aguacongas@gmail.com"
- COMMIT_AUTHOR_EMAIL: aguacongas@gmail.com
- secure: of+iC6cKMms3Vo61mTFnff+v9xJxk6VsD0bd/398r3ie4IlbpKVY6KEJ3QsDLpNQrbng9991b8p3LK58mQjBGr+Mr9S4Jan7k68MLd5JJkjDn8wQEn6ENQTtjQs1PjRI8bss3zHbvb+/ZFDqg1K5O4sVTrioW3Pqz39Vi2XCbSJNXCYF5OweZmJQm4/umW+zjOf5QdNWdL8WP+s1w7incExYykRDMp6ry9nE98V7lI2sH4zM3MZOkfXUSRnP51N0Z5/kHY5/h9gHq0rFefTrK7N8AicQMSg2QylZRIBDu9OO6Qo91ap9E3bqF20xJURF3pki+pUTmPjhEg12W6NDpQr59MuGmyMYB0d/PE79Oq9d463dOyUdWS29wXf/+Ask0r5ZmNPqJMNULUcVw9BoJq4UavKWvoOySycyRDDGwovGPORo8+cEMUer7bGSNj9BQkE9BhbUkqF+6Y2KWVhGzUTTmHaTvLMqmcCnfbsUbDy+XuEJnnq6l1B98jfHD73GQvfHYNefsaoKEGfpzu4RrKWwypluxSYg0Zhl70z6YDpiYFgqpGtXPURCqF5o8JUbnDgbDm1g6wUQKaf89Cv8kb6pXJ4M/1jlk5NpUEpJzcuH+SlfrhxMDzyoa4K3lZUHNc5iU7CZLaVkZ1NaPwNc0+UwMSb4u5uPtuBuEu4X7v0=
after_success:
- chmod a+x travis-deploy.sh
- ./travis-deploy.sh
- "./travis-deploy.sh"
17 changes: 3 additions & 14 deletions travis-deploy.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,7 @@ if [ "$TRAVIS_PULL_REQUEST" != "false" -o "$TRAVIS_BRANCH" != "$SOURCE_BRANCH" ]
fi

# Save some useful information
REPO=`git config remote.origin.url`
SSH_REPO=${REPO/https:\/\/github.com\//git@github.com:}
REPO=`https://$GH_TOKEN@github.com/aguacongas/chatle.aurelia.git`
SHA=`git rev-parse --verify HEAD`

# Clone the existing gh-pages for this repo into out/
Expand All @@ -31,7 +30,7 @@ cp wwwroot/scripts/*.js out/scripts
# Now let's go have some fun with the cloned repo
cd out
git config user.name "Travis CI"
git config user.email "$COMMIT_AUTHOR_EMAIL"
git config user.email "aguacongas@gmail.com"

# If there are no changes to the compiled out (e.g. this is a README update) then just bail.
if [ -z `git diff --exit-code` ]; then
Expand All @@ -44,15 +43,5 @@ fi
git add .
git commit -m "Deploy to GitHub Pages: ${SHA}"

# Get the deploy key by using Travis's stored variables to decrypt deploy_key.enc
ENCRYPTED_KEY_VAR="encrypted_${ENCRYPTION_LABEL}_key"
ENCRYPTED_IV_VAR="encrypted_${ENCRYPTION_LABEL}_iv"
ENCRYPTED_KEY=${!ENCRYPTED_KEY_VAR}
ENCRYPTED_IV=${!ENCRYPTED_IV_VAR}
openssl aes-256-cbc -K $ENCRYPTED_KEY -iv $ENCRYPTED_IV -in ../id_rsa.enc -out ../id_rsa -d
chmod 600 ../id_rsa
eval `ssh-agent -s`
ssh-add ../id_rsa

# Now that we're all set up, we can push.
git push $SSH_REPO $TARGET_BRANCH
git push $TARGET_BRANCH

0 comments on commit 926ecb1

Please sign in to comment.