Commit 946b4110 by Paul

ci: add Travis build file

parent ea07b88c
Pipeline #4975188 failed with stage
in 1 minute 16 seconds
......@@ -16,3 +16,6 @@
# Ignore .DS_store file
.DS_Store
deploy_key.pem
deploy_key.pem.pub
\ No newline at end of file
2.2
\ No newline at end of file
language: ruby
install:
- bundle install --path vendor/bundle
script:
- bundle exec middleman build --clean
after_success:
- openssl aes-256-cbc -K $encrypted_cd32eca6684a_key -iv $encrypted_cd32eca6684a_iv -in deploy_key.pem.enc -out deploy_key.pem -d
- eval "$(ssh-agent -s)"
- chmod 600 deploy_key.pem
- ssh-add deploy_key.pem
deploy:
skip_cleanup: true
provider: script
script: scripts/deploy.sh
on:
branch: master
#!/bin/bash -e
# Commit middleman build directory
git clean -dfx -e public -e deploy_key.pem
mv public/* .
git add .
git commit -m "deploy: publishing github pages $(date)"
repo="$(git config --get remote.origin.url)"
ssh_repo="${repo/https:\/\/github.com\//git@github.com:}"
# Push to gh-pages branch!
git remote set-url origin $ssh_repo
git push -f origin HEAD:gh-pages
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment