diff --git a/README.md b/README.md index 60db802..65581f8 100644 --- a/README.md +++ b/README.md @@ -69,7 +69,7 @@ repos: - id: clang-format args: [--style=Google] # Other coding style: LLVM, GNU, Chromium, Microsoft, Mozilla, WebKit. - id: clang-tidy - args: [--checks='boost-*,bugprone-*,performance-*,readability-*,portability-*,modernize-*,clang-analyzer-*,cppcoreguidelines-*'] + args: ["--checks=boost-*,bugprone-*,performance-*,readability-*,portability-*,modernize-*,clang-analyzer-*,cppcoreguidelines-*"] ``` ### Custom Configuration Files @@ -83,8 +83,7 @@ repos: hooks: - id: clang-format args: [--style=file] # Loads style from .clang-format file - - id: clang-tidy - args: [--checks=.clang-tidy] # Loads checks from .clang-tidy file + - id: clang-tidy # clang-tidy reads your .clang-tidy file by itself ``` > [!TIP] @@ -102,7 +101,7 @@ repos: - id: clang-format args: [--style=file, --version=21] # Specifies version - id: clang-tidy - args: [--checks=.clang-tidy, --version=21] # Specifies version + args: [--version=21] # Specifies version ``` > [!TIP] @@ -124,7 +123,6 @@ repos: rev: v1.6.0 hooks: - id: clang-tidy - args: [--checks=.clang-tidy] # Auto-detects ./build/compile_commands.json if present ``` @@ -132,21 +130,21 @@ To specify the build directory explicitly: ```yaml - id: clang-tidy - args: [--compile-commands=build, --checks=.clang-tidy] + args: [--compile-commands=build] ``` To disable auto-detection (e.g. in a monorepo where auto-detect might pick the wrong database): ```yaml - id: clang-tidy - args: [--no-compile-commands, --checks=.clang-tidy] + args: [--no-compile-commands] ``` To see which `compile_commands.json` the hook is using, add `-v`: ```yaml - id: clang-tidy - args: [--compile-commands=build, -v, --checks=.clang-tidy] + args: [--compile-commands=build, -v] ``` > [!NOTE] @@ -239,7 +237,7 @@ repos: rev: v1.6.0 # includes --fix support hooks: - id: clang-tidy - args: [--checks=.clang-tidy, --fix] + args: [--fix] ``` > [!WARNING] @@ -261,7 +259,7 @@ repos: args: [--style=file, --version=21] files: ^(src|include)/.*\.(cpp|cc|cxx|h|hpp)$ # Limits to specific dirs and file types - id: clang-tidy - args: [--checks=.clang-tidy, --version=21] + args: [--version=21] files: ^(src|include)/.*\.(cpp|cc|cxx|h|hpp)$ ``` @@ -273,7 +271,7 @@ or `-j`: rev: v1.6.0 hooks: - id: clang-tidy - args: [--checks=.clang-tidy, --version=21, --jobs=4] + args: [--version=21, --jobs=4] ``` > [!WARNING] @@ -304,7 +302,7 @@ repos: - id: clang-format args: [--style=file, --version=21, --verbose] # Shows processed files - id: clang-tidy - args: [--checks=.clang-tidy, --verbose] # Shows which compile_commands.json is used + args: [--verbose] # Shows which compile_commands.json is used ``` ## Examples @@ -318,19 +316,19 @@ Two self-contained templates plus quick snippets for other common setups. ## Used By
-
- Bosch Research
MIT ACL
Bazel Contrib
CodSpeed
-
- Jupyter Xeus
+
+ doldecomp
+
+ HKUST Aerial Robotics
-
- Rancher Sandbox
+
+ Kubewarden
Computational Geography
@@ -339,7 +337,7 @@ Two self-contained templates plus quick snippets for other common setups.
CONVINCE-Project
and many more.
- See the cpp-linter hub for the full list of organizations using cpp-linter tools.
+ See the cpp-linter showcase for projects using cpp-linter tools.