aboutsummaryrefslogtreecommitdiffstats
path: root/wscript
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2018-09-15 11:53:11 +0200
committerDavid Robillard <d@drobilla.net>2018-09-15 11:53:11 +0200
commitbefca854f84b1ebf730dd45b5e63a7928039b32d (patch)
tree9bdf9118de4fd560c57ee94027acd26923e332aa /wscript
parent4de165e8429238eca29e8a8bdfc8e3e55973b0db (diff)
downloadpugl-befca854f84b1ebf730dd45b5e63a7928039b32d.tar.gz
pugl-befca854f84b1ebf730dd45b5e63a7928039b32d.tar.bz2
pugl-befca854f84b1ebf730dd45b5e63a7928039b32d.zip
Use clang-tidy for linting
Diffstat (limited to 'wscript')
-rw-r--r--wscript11
1 files changed, 10 insertions, 1 deletions
diff --git a/wscript b/wscript
index 903c6e0..6023cc8 100644
--- a/wscript
+++ b/wscript
@@ -173,7 +173,16 @@ def build(bld):
def lint(ctx):
"checks code for style issues"
- subprocess.call('cpplint.py --filter=+whitespace/comments,-whitespace/tab,-whitespace/braces,-whitespace/labels,-build/header_guard,-readability/casting,-readability/todo,-build/include src/* pugl/*', shell=True)
+ import subprocess
+ cmd = ("clang-tidy -p=. -header-filter=.* -checks=\"*," +
+ "-clang-analyzer-alpha.*," +
+ "-google-readability-todo," +
+ "-llvm-header-guard," +
+ "-misc-unused-parameters," +
+ "-hicpp-signed-bitwise," + # FIXME?
+ "-readability-else-after-return\" " +
+ "../pugl/*.c ../*.c")
+ subprocess.call(cmd, cwd='build', shell=True)
# Alias .m files to be compiled the same as .c files, gcc will do the right thing.
from waflib import TaskGen