From a290e19f461700e6449c53fce26865d3d746731e Mon Sep 17 00:00:00 2001 From: ISSOtm Date: Tue, 3 Dec 2019 23:09:07 +0100 Subject: [PATCH] Make `make checkcodebase` ignore `extern/` That folder contains external code, and modifying it to conform to our code style would make applying upstream patches, amongst others, problematic. Therefore, skip checking it. Ideally, the folder should also be excluded from `make checkpatch`, but I haven't figured out a way to do that yet. --- Makefile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 05ccddaf..a5d85550 100644 --- a/Makefile +++ b/Makefile @@ -168,10 +168,12 @@ install: all $Qinstall -m ${MANMODE} src/gfx/rgbgfx.1 ${DESTDIR}${mandir}/man1/rgbgfx.1 # Target used to check the coding style of the whole codebase. +# `extern/` is excluded, as it contains external code that should not be patched +# to meet our coding style, so applying upstream patches is easier. # `.y` files aren't checked, unfortunately... checkcodebase: - $Qfor file in `git ls-files | grep -E '\.c|\.h' | grep -v '\.html'`; do \ + $Qfor file in `git ls-files | grep -E '(\.c|\.h)$$' | grep -Ev '(src|include)/extern/'`; do \ ${CHECKPATCH} -f "$$file"; \ done