From ff5aa9481b91cbe7f4497b2e6608cec4e643289e Mon Sep 17 00:00:00 2001 From: David Robillard Date: Fri, 29 Dec 2017 14:54:58 -0500 Subject: Use clang-tidy for linting --- wscript | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/wscript b/wscript index ea785f3..b1d12ec 100644 --- a/wscript +++ b/wscript @@ -385,7 +385,22 @@ def build(bld): bld.add_post_fun(lambda ctx: autowaf.make_simple_dox(APPNAME)) def lint(ctx): - subprocess.call('cpplint.py --filter=-whitespace,+whitespace/comments,-build/header_guard,-readability/casting,-readability/todo src/* suil/*', shell=True) + "checks code for style issues" + import subprocess + cmd = ("clang-tidy -p=. -header-filter=suil/ -checks=\"*," + + "-clang-analyzer-alpha.*," + + "-cppcoreguidelines-*," + + "-google-readability-todo," + + "-llvm-header-guard," + + "-llvm-include-order," + + "-misc-unused-parameters," + + "-misc-unused-parameters," + + "-modernize-*," + + "-readability-else-after-return," + + "-readability-implicit-bool-cast\" " + + "$(find .. -name '*.c' -or -name '*.cpp' -or -name '*.mm')") + print cmd + subprocess.call(cmd, cwd='build', shell=True) def release(ctx): autowaf.release(APPNAME.title(), VERSION) -- cgit v1.2.1