Module: check_mk
Branch: master
Commit: 831152369a7548432dacd80f7d219534b65c1454
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=831152369a7548…
Author: Sven Panne <sp(a)mathias-kettner.de>
Date: Thu Feb 21 08:12:56 2019 +0100
Improve linter script.
Change-Id: Ia8c26293171ccb1ec4538c93cb41895aebf0d002
---
scripts/run-cxx-linter | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/scripts/run-cxx-linter b/scripts/run-cxx-linter
index ef5ff68..4c76662 100755
--- a/scripts/run-cxx-linter
+++ b/scripts/run-cxx-linter
@@ -3,6 +3,13 @@ set -e
TARGET=$1
PATCHSET_REVISION=$2
+# To really compute *only* the files which need checking, we better make sure
+# that our project is up-to-date without any further changes first (i.e. target
+# "all-am"). Having an up-to-date project file before running a linter is a
good
+# idea, too (i.e. target "compile_commands.json"). The latter target implies
the
+# former, so we just do that.
+make compile_commands.json
+
# ATTENTION! Extremely cunning hack ahead! Find out which files have been
# changed in the current directory for the given commit. Transform those file
# names into --what-if=... options for make and do a dry run with them. This