diff options
| author | Philipp Krones <hello@philkrones.com> | 2023-01-27 20:21:37 +0100 |
|---|---|---|
| committer | Philipp Krones <hello@philkrones.com> | 2023-01-27 20:26:35 +0100 |
| commit | 2bc2431fd18c212ca081f67f4d853645f83437f5 (patch) | |
| tree | c86f5bf3ad33a6dca050110cec70e0bc38fac1cd /book/src/development/adding_lints.md | |
| parent | a64940f948757ffe4b0705726b497b552801a93d (diff) | |
| parent | 54e929bddee5934c527894fabee8a2c48531a795 (diff) | |
Merge remote-tracking branch 'upstream/master' into rustup
Diffstat (limited to 'book/src/development/adding_lints.md')
| -rw-r--r-- | book/src/development/adding_lints.md | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/book/src/development/adding_lints.md b/book/src/development/adding_lints.md index 8b4eee8c9d9..f57dc627dce 100644 --- a/book/src/development/adding_lints.md +++ b/book/src/development/adding_lints.md @@ -146,7 +146,8 @@ For cargo lints, the process of testing differs in that we are interested in the manifest. If our new lint is named e.g. `foo_categories`, after running `cargo dev -new_lint` we will find by default two new crates, each with its manifest file: +new_lint --name=foo_categories --type=cargo --category=cargo` we will find by +default two new crates, each with its manifest file: * `tests/ui-cargo/foo_categories/fail/Cargo.toml`: this file should cause the new lint to raise an error. @@ -699,6 +700,10 @@ for some users. Adding a configuration is done in the following steps: `clippy.toml` file with the configuration value and a rust file that should be linted by Clippy. The test can otherwise be written as usual. +5. Update [Lint Configuration](../lint_configuration.md) + + Run `cargo collect-metadata` to generate documentation changes for the book. + [`clippy_lints::utils::conf`]: https://github.com/rust-lang/rust-clippy/blob/master/clippy_lints/src/utils/conf.rs [`clippy_lints` lib file]: https://github.com/rust-lang/rust-clippy/blob/master/clippy_lints/src/lib.rs [`tests/ui`]: https://github.com/rust-lang/rust-clippy/blob/master/tests/ui |
