diff --git a/.github/workflows/clang-tidy.yaml b/.github/workflows/clang-tidy.yaml new file mode 100644 index 00000000000..6cdb69c3ce7 --- /dev/null +++ b/.github/workflows/clang-tidy.yaml @@ -0,0 +1,29 @@ +name: clang-tidy-review + +on: + push: + branches: ['**'] + pull_request: + branches: ['**'] + +permissions: read-all + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + + # Optionally generate compile_commands.json + + - uses: ZedThree/clang-tidy-review@v0.14.0 + id: review + + # Uploads an artefact containing clang_fixes.json + - uses: ZedThree/clang-tidy-review/upload@v0.14.0 + id: upload-review + + # If there are any comments, fail the check + - if: steps.review.outputs.total_comments > 0 + run: exit 1 \ No newline at end of file diff --git a/src/ds/d500/d500-device.cpp b/src/ds/d500/d500-device.cpp index 3c93be12da9..415a05b98ec 100644 --- a/src/ds/d500/d500-device.cpp +++ b/src/ds/d500/d500-device.cpp @@ -1,7 +1,7 @@ // License: Apache 2.0. See LICENSE file in root directory. // Copyright(c) 2022 Intel Corporation. All Rights Reserved. -#include "metadata-parser.h" +#include "metadata-parser.h" #include "metadata.h" #include #include diff --git a/src/ds/d500/d500-factory.cpp b/src/ds/d500/d500-factory.cpp index 46f01f27ba8..6e1692bf09e 100644 --- a/src/ds/d500/d500-factory.cpp +++ b/src/ds/d500/d500-factory.cpp @@ -1,7 +1,7 @@ // License: Apache 2.0. See LICENSE file in root directory. // Copyright(c) 2022 Intel Corporation. All Rights Reserved. -#include "device.h" +#include "device.h" #include "image.h" #include "metadata-parser.h" diff --git a/src/ds/d500/d500-options.cpp b/src/ds/d500/d500-options.cpp index 57ee6e8bc57..53023f1cfd5 100644 --- a/src/ds/d500/d500-options.cpp +++ b/src/ds/d500/d500-options.cpp @@ -2,7 +2,7 @@ // Copyright(c) 2023 Intel Corporation. All Rights Reserved. -#include "d500-options.h" +#include "d500-options.h" namespace librealsense {