I want to be able to use linting to allow and deny some operating from because executed like a code which is not well indent or has unused variables
Here a description of how to configure lints:
(all three options, namely (I) attributes in your code, (II) CLI option during compilation and (III) your manifest file are not specific to clippy and can be applied to rustc lints as well)
Not sure if there exist a lint for bad formatting. Usually a formatter is used for this instead of a linter, like rustfmt
. You can run rustfmt
like a linter (i.e. not letting it apply proper formatting directly to your codebase but instead letting it print places that are badly formatted to your console) with the --check
flag.
3 Likes
Thanks this was so helpful