dotfiles/.local/bin/scripts/pre-commit-install
2021-11-25 13:59:18 +01:00

6 lines
256 B
Bash
Executable file

#!/bin/sh
# Install pre-commit, ignoring globally set core.hooksPath
git config --unset-all core.hooksPath
GIT_CONFIG_GLOBAL=/dev/null pre-commit install
GIT_CONFIG_GLOBAL=/dev/null pre-commit install -t pre-push
git config --add core.hooksPath .git/hooks