diff --git a/scripts/check-licence-header.sh b/scripts/check-licence-header.sh index 480e370f1922808b58cde558ea2dfab8e0f56e21..a9b2502c26029057c4b05579ab0be0bb302c363e 100755 --- a/scripts/check-licence-header.sh +++ b/scripts/check-licence-header.sh @@ -9,6 +9,10 @@ # For all the directories/files listed in the array an explanation should be given. excludes=( +# The directory external is excluded from the check since this directory +# contains code which isn't part of CbmRoot but external dependencies so +# we don't have to test for our license header +external # The directory is excluded since the files have a license header # inherited from the ALICE experiment. The code was copied by the # original author when he started working for CBM. @@ -83,7 +87,7 @@ for FILE in $CHANGED_FILES; do for EXCLUDE in "${excludes[@]}"; do FILE=$(echo $FILE | egrep -v "$EXCLUDE") done - if [[ -n $FILE ]]; then + if [[ -n $FILE && -f $FILE ]]; then licenceHeaderCheck $FILE fi done