diff options
| author | Bartek IwaĆczuk <biwanczuk@gmail.com> | 2023-07-25 23:24:06 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-07-25 17:24:06 -0400 |
| commit | 88885d9c2b6f2ae12e97f17bccb0c7a0225380a1 (patch) | |
| tree | c888f27ee989ec103df7fcae660e07c75a2b2d4d /cli/tools | |
| parent | 4a5aaceb26cb7441d0702d30961e0059256826b7 (diff) | |
fix(lint): allow to use --rules with --rules-tags (#19754)
Diffstat (limited to 'cli/tools')
| -rw-r--r-- | cli/tools/lint.rs | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/cli/tools/lint.rs b/cli/tools/lint.rs index 4a622f0a0..f5e9db6e9 100644 --- a/cli/tools/lint.rs +++ b/cli/tools/lint.rs @@ -202,8 +202,12 @@ fn collect_lint_files(files: &FilesConfig) -> Result<Vec<PathBuf>, AnyError> { .collect_files(&files.include) } -pub fn print_rules_list(json: bool) { - let lint_rules = rules::get_recommended_rules(); +pub fn print_rules_list(json: bool, maybe_rules_tags: Option<Vec<String>>) { + let lint_rules = get_configured_rules(LintRulesConfig { + exclude: None, + include: None, + tags: maybe_rules_tags, + }); if json { let json_rules: Vec<serde_json::Value> = lint_rules |
