Check rustfmt formatting in travis builds (#210)

* Install rustfmt

* Check formatting in travis builds
This commit is contained in:
Philipp Oppermann
2016-08-27 13:45:18 +02:00
committed by GitHub
parent 68921b625d
commit 9830f4ef48
2 changed files with 6 additions and 0 deletions

View File

@@ -5,6 +5,8 @@ rust:
cache: cargo
before_script: (cargo install rustfmt || true)
sudo: false
notifications:

View File

@@ -5,6 +5,10 @@ set -e
# build rust project
make
# check formatting (rustfmt)
PATH=~/.cargo/bin:$PATH
cargo fmt -- --write-mode=diff
# clone hugo branch, which contains the blog template
git clone --branch=hugo https://github.com/phil-opp/blog_os.git hugo
cd hugo