Last active
February 16, 2025 19:40
-
-
Save tombh/d888f54328e4fbed7e84d72d5bd6f5f6 to your computer and use it in GitHub Desktop.
Loudest Cargo π± How to setup Clippy to be as verbose as possible.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Canonical lints for whole crate | |
# | |
# Official docs: | |
# https://doc.rust-lang.org/nightly/clippy/lints.html | |
# Useful app to lookup full details of individual lints: | |
# https://rust-lang.github.io/rust-clippy/master/index.html | |
# | |
# We set base lints to give the fullest, most pedantic feedback possible. | |
# Though we prefer that they are just warnings during development so that build-denial | |
# is only enforced in CI. | |
[lints.rust] | |
# It's always good to write as much documentation as possible | |
missing_docs = "warn" | |
[lints.clippy] | |
# `clippy::all` is already on by default. It implies the following: | |
# * clippy::correctness code that is outright wrong or useless | |
# * clippy::suspicious code that is most likely wrong or useless | |
# * clippy::complexity code that does something simple but in a complex way | |
# * clippy::perf code that can be written to run faster | |
# * clippy::style code that should be written in a more idiomatic way | |
all = { level = "warn", priority = -1 } | |
# > clippy::pedantic lints which are rather strict or might have false positives | |
pedantic = { level = "warn", priority = -1 } | |
# > new lints that are still under development | |
# (so "nursery" doesn't mean "Rust newbies") | |
nursery = { level = "warn", priority = -1 } | |
# > The clippy::cargo group gives you suggestions on how to improve your Cargo.toml file. | |
# > This might be especially interesting if you want to publish your crate and are not sure | |
# > if you have all useful information in your Cargo.toml. | |
cargo = { level = "warn", priority = -1 } | |
# > The clippy::restriction group will restrict you in some way. | |
# > If you enable a restriction lint for your crate it is recommended to also fix code that | |
# > this lint triggers on. However, those lints are really strict by design and you might want | |
# > to #[allow] them in some special cases, with a comment justifying that. | |
restriction = { level = "warn", priority = -1 } | |
blanket_clippy_restriction_lints = "allow" | |
# Individually blanket-allow single lints relevant to this whole crate | |
#arithmetic_side_effects = "allow" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment