From 90d206018865fe68a341243ea6e3925a772b1e54 Mon Sep 17 00:00:00 2001 From: Martine Lenders Date: Thu, 7 Dec 2017 11:00:12 +0100 Subject: [PATCH] docheck: make doccheck executable from any directory The doccheck script reports reports a false positive when executed from any directory but `RIOTBASE`. With this fix, `make doc` changes into the currently unused `RIOTBASE` variable. This is an alternative approach to #7217, which removes this variable, but keeps the false positive aspect of the script untouched. --- dist/tools/doccheck/check.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/dist/tools/doccheck/check.sh b/dist/tools/doccheck/check.sh index ef618fbd22..831b494dc0 100755 --- a/dist/tools/doccheck/check.sh +++ b/dist/tools/doccheck/check.sh @@ -8,7 +8,9 @@ RIOTBASE=$(readlink -f "$(dirname $(realpath $0))/../../..") -ERRORS=$(make doc 2>&1 | grep '.*warning' | sed "s#${PWD}/\([^:]*\)#\1#g") +ERRORS=$(make -C "${RIOTBASE}" doc 2>&1 | \ + grep '.*warning' | \ + sed "s#${PWD}/\([^:]*\)#\1#g") if [ -n "${ERRORS}" ] then