diff --git a/hooks/deny_binary b/hooks/deny_binary index 48e5ace..ccf08a0 100755 --- a/hooks/deny_binary +++ b/hooks/deny_binary @@ -52,8 +52,7 @@ while read oldrev newrev refname; do fi # Loop over each commit. - for commit in $(git rev-list --objects ${rev_range} | - git cat-file --batch-check='%(objectname) %(objecttype) %(objectsize) %(rest)' | grep commit | awk '{print $1}'); do + for commit in $(git rev-list --objects ${rev_range} --filter=object:type=commit); do # Get list of potentially binary files in this commit mapfile -t binary_files < <(