diff --git a/test/lint/lint-includes.sh b/test/lint/lint-includes.sh index 4b9e2615b..d27e45a23 100755 --- a/test/lint/lint-includes.sh +++ b/test/lint/lint-includes.sh @@ -11,6 +11,9 @@ export LC_ALL=C IGNORE_REGEXP="/(leveldb|secp256k1|univalue)/" +# cd to root folder of git repo for git ls-files to work properly +cd "$(dirname $0)/../.." || exit 1 + filter_suffix() { git ls-files | grep -E "^src/.*\.${1}"'$' | grep -Ev "${IGNORE_REGEXP}" }