Mention running optional clippy dependency with cargo rustc

This commit is contained in:
Tim Neumann 2016-03-24 23:03:51 +01:00
parent 7e65493599
commit e53babef8f

View file

@ -233,6 +233,8 @@ And, in your `main.rs` or `lib.rs`:
#![cfg_attr(feature="clippy", plugin(clippy))]
```
Instead of adding the `cfg_attr` attributes you can also run clippy on demand: `cargo rustc --features clippy -- -Z no-trans -Z extra-plugins=clippy` (the `-Z no trans`, while not neccessary, will stop the compilation process after typechecking (and lints) have completed, which can significantly reduce the runtime).
## Configuration
Some lints can be configured in a `clippy.toml` file. It contains basic `variable = value` mapping eg.