combine find commands, exclude .git folder

This commit is contained in:
aptalca 2023-03-21 11:29:17 -04:00
parent 0798c3f6cd
commit 0ab04b6245
No known key found for this signature in database
GPG Key ID: BE36CFFB9FD85548

View File

@ -11,7 +11,7 @@ jobs:
fetch-depth: '0'
- name: Check Permissions
run: |
WRONG_PERM=$(find ./ -name run -not -perm -u=x,g=x,o=x && find ./ -name finish -not -perm -u=x,g=x,o=x && find ./ -name check -not -perm -u=x,g=x,o=x)
WRONG_PERM=$(find ./ -path "./.git" -prune -o \( -name "run" -o -name "service" -o -name "check" \) -not -perm -u=x,g=x,o=x -print)
if [ -n "${WRONG_PERM}" ]; then
for i in ${WRONG_PERM}; do
echo "::error file=${i},line=1,title=Missing Executable Bit::This file needs to be set as executable!"