Commit 3e29d23
authored
fix(linter): use aliases when parsing cli rules (#14912)
- Fixes #14906
#### What went wrong
- `parse_rule_key` has the logic for aliasing, and it is called by
`OxlintRules`, but only during deserialization.
- `CliRunner`, via `ConfigStoreBuilder`, instantiates `OxlintRules`
directly. No post processing, aliasing doesn't take place.
#### Fix
- Aliasing logic in `parse_rule_key` is split off as
`unalias_plugin_name`.
- `unalias_plugin_name` is now called by `ConfigStoreBuilder`.
- `LintFilterKind::parse` seemed like a better place at first, but
lifetimes required cloning.1 parent b94b6aa commit 3e29d23
2 files changed
+46
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
305 | 305 | | |
306 | 306 | | |
307 | 307 | | |
| 308 | + | |
308 | 309 | | |
309 | 310 | | |
310 | 311 | | |
| |||
317 | 318 | | |
318 | 319 | | |
319 | 320 | | |
| 321 | + | |
320 | 322 | | |
321 | 323 | | |
322 | 324 | | |
| |||
857 | 859 | | |
858 | 860 | | |
859 | 861 | | |
| 862 | + | |
| 863 | + | |
| 864 | + | |
| 865 | + | |
| 866 | + | |
| 867 | + | |
| 868 | + | |
| 869 | + | |
| 870 | + | |
| 871 | + | |
| 872 | + | |
| 873 | + | |
| 874 | + | |
| 875 | + | |
| 876 | + | |
| 877 | + | |
| 878 | + | |
| 879 | + | |
| 880 | + | |
| 881 | + | |
| 882 | + | |
| 883 | + | |
| 884 | + | |
| 885 | + | |
| 886 | + | |
| 887 | + | |
| 888 | + | |
| 889 | + | |
| 890 | + | |
| 891 | + | |
| 892 | + | |
| 893 | + | |
| 894 | + | |
| 895 | + | |
| 896 | + | |
| 897 | + | |
| 898 | + | |
| 899 | + | |
| 900 | + | |
| 901 | + | |
| 902 | + | |
860 | 903 | | |
861 | 904 | | |
862 | 905 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
240 | 240 | | |
241 | 241 | | |
242 | 242 | | |
| 243 | + | |
| 244 | + | |
243 | 245 | | |
| 246 | + | |
244 | 247 | | |
245 | 248 | | |
246 | 249 | | |
| |||
0 commit comments