From 4623b43890ff1aeb2cd9ab4cda48fc193664a8f8 Mon Sep 17 00:00:00 2001 From: Bradlee Speice Date: Sat, 8 Dec 2018 19:10:25 -0500 Subject: [PATCH] Handle rustfmt installation better --- .travis.yml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 05f2aa0..8bcd8da 100644 --- a/.travis.yml +++ b/.travis.yml @@ -42,7 +42,11 @@ install: - source ~/.cargo/env || true script: - - rustup component add rustfmt + - if [ "$TRAVIS_RUST_VERSION" == "nightly" ]; then + rustup component add rustfmt-preview + else + rustup component add rustfmt + fi - cargo fmt --all -- --check - | if [ -z "$TRAVIS_TAG" ]; then