7

I want to configure my -line-filter= arguments in the .clang-tidy file instead of in a cmake source file where the command is generated. Adding a LineFilter key to the file only gets me a "unknown key" error. Is this really not supported via the config file? Is there an alternative option?

renefritze
  • 2,167
  • 14
  • 25

1 Answers1

3

Unfortunately this is not supported, see source of ClangTidyOptions.h

/// Global options. These options are neither stored nor read from
 /// configuration files.
 struct ClangTidyGlobalOptions {
   /// Output warnings from certain line ranges of certain files only.
   /// If empty, no warnings will be filtered.
   std::vector<FileFilter> LineFilter;
 };
pablo285
  • 2,460
  • 4
  • 14
  • 38