use --cap-lints
only when deny and forbid rules are not specified
Signed-off-by: onur-ozkan <work@onurozkan.dev>
This commit is contained in:
parent
1945e8f1f6
commit
a61bf3093e
1 changed files with 7 additions and 2 deletions
|
@ -61,10 +61,15 @@ fn args(builder: &Builder<'_>) -> Vec<String> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
let all_args = std::env::args().collect::<Vec<_>>();
|
args.extend(strings(&["--"]));
|
||||||
|
|
||||||
args.extend(strings(&["--", "--cap-lints", "warn"]));
|
if deny.is_empty() && forbid.is_empty() {
|
||||||
|
args.extend(strings(&["--cap-lints", "warn"]));
|
||||||
|
}
|
||||||
|
|
||||||
|
let all_args = std::env::args().collect::<Vec<_>>();
|
||||||
args.extend(get_clippy_rules_in_order(&all_args, allow, deny, warn, forbid));
|
args.extend(get_clippy_rules_in_order(&all_args, allow, deny, warn, forbid));
|
||||||
|
|
||||||
args.extend(ignored_lints.iter().map(|lint| format!("-Aclippy::{}", lint)));
|
args.extend(ignored_lints.iter().map(|lint| format!("-Aclippy::{}", lint)));
|
||||||
args.extend(builder.config.free_args.clone());
|
args.extend(builder.config.free_args.clone());
|
||||||
args
|
args
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue