@@ -76,7 +76,8 @@ fn main() {
76
76
} ,
77
77
( "lint" , Some ( matches) ) => {
78
78
let path = matches. value_of ( "path" ) . unwrap ( ) ;
79
- lint:: run ( path) ;
79
+ let args = matches. values_of ( "args" ) . into_iter ( ) . flatten ( ) ;
80
+ lint:: run ( path, args) ;
80
81
} ,
81
82
( "rename_lint" , Some ( matches) ) => {
82
83
let old_name = matches. value_of ( "old_name" ) . unwrap ( ) ;
@@ -123,7 +124,7 @@ fn get_clap_config<'a>() -> ArgMatches<'a> {
123
124
* the lint count in README.md is correct\n \
124
125
* the changelog contains markdown link references at the bottom\n \
125
126
* all lint groups include the correct lints\n \
126
- * lint modules in `clippy_lints/*` are visible in `src/lifb .rs` via `pub mod`\n \
127
+ * lint modules in `clippy_lints/*` are visible in `src/lib .rs` via `pub mod`\n \
127
128
* all lints are registered in the lint store",
128
129
)
129
130
. arg ( Arg :: with_name ( "print-only" ) . long ( "print-only" ) . help (
@@ -278,11 +279,23 @@ fn get_clap_config<'a>() -> ArgMatches<'a> {
278
279
Lint a package directory:
279
280
cargo dev lint tests/ui-cargo/wildcard_dependencies/fail
280
281
cargo dev lint ~/my-project
282
+
283
+ Run rustfix:
284
+ cargo dev lint ~/my-project -- --fix
285
+
286
+ Set lint levels:
287
+ cargo dev lint file.rs -- -W clippy::pedantic
288
+ cargo dev lint ~/my-project -- -- -W clippy::pedantic
281
289
" } )
282
290
. arg (
283
291
Arg :: with_name ( "path" )
284
292
. required ( true )
285
293
. help ( "The path to a file or package directory to lint" ) ,
294
+ )
295
+ . arg (
296
+ Arg :: with_name ( "args" )
297
+ . multiple ( true )
298
+ . help ( "Pass extra arguments to cargo/clippy-driver" ) ,
286
299
) ,
287
300
)
288
301
. subcommand (
0 commit comments