summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2020-05-13 15:40:56 -0700
committerJohn MacFarlane <jgm@berkeley.edu>2020-05-13 15:40:56 -0700
commitb1dab7360ee9104e1c81d2010369bb2075811eb7 (patch)
tree2edd3efbd54185258b4bb0a9e764676f55572e33
parent4a47e6a34ce136658f790d78c9670efe2415a78e (diff)
Add lint target to Makefile
-rw-r--r--Makefile4
1 files changed, 3 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index dc82967..6f8f22e 100644
--- a/Makefile
+++ b/Makefile
@@ -93,8 +93,10 @@ libFuzzer:
test/run-cmark-fuzz $(CMARK_FUZZ)
lint: $(BUILDDIR)
+ errs=0 ; \
for f in `ls src/*.[ch] | grep -v "scanners.c"` ; \
- do echo $$f ; clang-tidy -header-filter='^build/.*' -p=build -warnings-as-errors='*' $$f || exit 1 ; done
+ do echo $$f ; clang-tidy -header-filter='^build/.*' -p=build -warnings-as-errors='*' $$f || errs=1 ; done ; \
+ exit $$errs
mingw:
mkdir -p $(MINGW_BUILDDIR); \