Add pre-commit hook.