Last active
December 18, 2015 21:29
-
-
Save dragonfax/5847823 to your computer and use it in GitHub Desktop.
make pre-commit a global default for all of your repos.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mkdir ~/.git_template | |
mkdir ~/.git_template/hooks | |
cp $(gem contents pre-commit | grep pre-commit-hook) ~/.git_template/hooks/pre-commit | |
git config --global init.templatedir '~/.git_template' | |
# also, to implement in any pre-existing repos, just execute 'git init' in them. | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment