[PATCH] D75184: [clang-tidy] Optional inheritance of file configs from parent directories 

Dmitry Polukhin via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Jun 15 10:23:37 PDT 2020


DmitryPolukhin added a comment.

In D75184#2093089 <https://reviews.llvm.org/D75184#2093089>, @njames93 wrote:

> As an afterthought, Would you think it a good idea to extend this logic to the `ConfigOptionsProvider` That way you can use something along the lines of:
>
>   clang-tidy --config='{InheritParentConfig: true, CheckOptions: [<Options overriding/complimenting .clang-tidy files>]}'
>
>
> clang-tidy would then go to read the .clang-tidy configuration files in much the same was as is done here. This would let you set custom configuration options on the command line on top of whats in configuration files.
>  Obviously is `InheritParentConfig` is unset or `false` then we wouldn't go looking for .clang-tidy files.


It sounds logical. I would even extend it a little bit to allow case `--config=@filepath` where filepath file will be read and expanded as the highest priority config. @njames93 are you going to work on this?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D75184/new/

https://reviews.llvm.org/D75184





More information about the cfe-commits mailing list