Can we add an option to clang-tidy to only runs checks that offer fixes?
The new option can be named something like --checks-with-fixes on the command line and ChecksWithFixes: true in the config file.
If the --checks or Checks: option is also specified then clang-tidy will only run the subset of specified checks that offer fixes.
For example, if the user specifies --checks-with-fixes --checks=-*,cppcoreguidelines-*,-cppcoreguidelines-init-variables, then clang-tidy will run all of the cppcoreguidelines checks that offer fixes except for cppcoreguidelines-init-variables.
Apologies if this is a duplicate - I searched and couldn't find any similar issues raised in the past.
Can we add an option to clang-tidy to only runs checks that offer fixes?
The new option can be named something like
--checks-with-fixes
on the command line andChecksWithFixes: true
in the config file.If the
--checks
orChecks:
option is also specified then clang-tidy will only run the subset of specified checks that offer fixes.For example, if the user specifies
--checks-with-fixes --checks=-*,cppcoreguidelines-*,-cppcoreguidelines-init-variables
, then clang-tidy will run all of thecppcoreguidelines
checks that offer fixes except forcppcoreguidelines-init-variables
.Apologies if this is a duplicate - I searched and couldn't find any similar issues raised in the past.