bazel: shebang-test: Test for all bin/env ...

Fail on any form of `bin/env ...` shebang.
This commit is contained in:
Andreas Herrmann 2019-08-19 14:29:07 +02:00 committed by Florian Klink
parent f6572b4e64
commit 1987d86007

View File

@ -25,7 +25,7 @@ let
check_shebangs() {
local dir="$1"
{ grep -Re '#!/usr/bin' $dir && FAIL=1; } || true
{ grep -Re '#![^[:space:]]*/bin/env python' $dir && FAIL=1; } || true
{ grep -Re '#![^[:space:]]*/bin/env' $dir && FAIL=1; } || true
}
BAZEL_EXTRACTED=${extracted bazel}/install
check_shebangs $BAZEL_EXTRACTED