Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
pre-commit git hook to stop you from commiting binding.pry
#!/bin/sh
exec 1>&2
if test $(git diff --cached -S'binding.pry' --name-only |
LC_ALL=C tr -d '[ -~]\0' | wc -c) != 0
then
cat <<\EOF
Remove biniding.pry
EOF
exit 1
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment