Skip to content

Conversation

@ivikhrev
Copy link

@ivikhrev ivikhrev commented Apr 1, 2022

Based on openvino scripts (https://github.com/openvinotoolkit/openvino/tree/master/cmake/developer_package/clang_format and https://github.com/openvinotoolkit/openvino/tree/master/cmake/developer_package/cpplint).

Now each buildable target has 3 connected targets: <target_name>_cpplint, <target_name>_clang, <target_name>_clang_fix.
By default enabled only clang-format checks. When build target with cmake --build will be triggered corresponding clang_fix task which automatically apply code style changes. To run only clang-format checks for all targets pass to the cmake --build . --target <target_name> clang_format_check_all or clang_format_fix_all to apply code style fixes.
To start cpplint checks you should pass to cmake parameter -DENABLE_CPPLINT=ON and then build<target_name>_cpplintfor individual targets or cpplint_all to check all targets.

@ivikhrev ivikhrev requested a review from Wovchena April 1, 2022 16:26
@ivikhrev ivikhrev force-pushed the add-style-checkers branch 2 times, most recently from f88a479 to b358c6e Compare April 4, 2022 09:08
@vladimir-dudnik
Copy link
Contributor

pre-commit check failed
12:11:40 running documentation checks...
12:11:44 cmake/cpplint/cpplint.py: has a shebang line, but isn't executable
12:11:44 cmake/cpplint/cpplint.py:1: use 'python3', not 'python'

@ivikhrev ivikhrev force-pushed the add-style-checkers branch 2 times, most recently from 3e191e4 to 05266c9 Compare April 4, 2022 12:06
@ivikhrev ivikhrev force-pushed the add-style-checkers branch from cad1e49 to e243e88 Compare April 4, 2022 13:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants