blob: de8ede82ca06c6c553c3a79a8575ccdc2e3286f9 [file] [log] [blame] [edit]
#!/usr/bin/env bash
set -xeu
cd "$(dirname "$0")/.."
rustup update nightly
rustup component add rustfmt --toolchain nightly
# Run `rustfmt` on the crate! If `rustfmt` can't make a long line shorter, it
# prints an error and exits non-zero, so tell it to kindly shut its yapper and
# make sure it doesn't cause us to exit this whole script non-zero.
rustup run nightly cargo fmt -- --check