Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update rust-toolchain and install rustfmt on CI #290

Merged
merged 4 commits into from
Aug 16, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 10 additions & 5 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,17 @@ services:
- docker
language: rust
before_install:
- rustup component add rustfmt
- cargo fmt --all -- --check
install:
- curl https://cli-assets.heroku.com/install-ubuntu.sh | sh
before_script:
- heroku container:login
- heroku container:pull --app=rfcbot-rs web
before_script: |
if [ "$TRAVIS_PULL_REQUEST" = "false" ]; then
heroku container:login
heroku container:pull --app=rfcbot-rs web
fi
script: |
heroku container:push --app=rfcbot-rs web
if [ "$TRAVIS_PULL_REQUEST" = "false" ]; then heroku container:push --app=rfcbot-rs web; fi
docker-compose up -d
docker-compose exec web cargo test --release --locked
after_failure:
Expand All @@ -24,8 +27,10 @@ cache:
directories:
- "$HOME/.cargo"
before_deploy: |
if [ "$TRAVIS_PULL_REQUEST" = "false" ]; then
docker-compose exec -e DATABASE_URL=$(heroku config:get DATABASE_URL --app=rfcbot-rs) web \
diesel migration run
fi
deploy:
provider: script
script: heroku container:release --app=rfcbot-rs web
script: if [ "$TRAVIS_PULL_REQUEST" = "false" ]; then heroku container:release --app=rfcbot-rs web; fi
Loading