Skip to content

Commit

Permalink
Do not list files when no source file is changed
Browse files Browse the repository at this point in the history
  • Loading branch information
jserv committed Sep 7, 2020
1 parent ef85925 commit eaa393e
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions scripts/pre-commit.hook
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,10 @@ for FILE in $FILES; do
fi
done

echo "Following files need to be cleaned up:"
echo "${FILES[*]}"
if [ ! -z "${FILES[*]}" ]; then
echo "Following files need to be cleaned up:"
echo "${FILES[*]}"
fi

# Prevent unsafe functions
root=$(git rev-parse --show-toplevel)
Expand Down

0 comments on commit eaa393e

Please sign in to comment.