Last active
August 29, 2015 14:19
-
-
Save achikin/d6a32ed42d5735d7f24d to your computer and use it in GitHub Desktop.
.git/hooks/prepare-commit-msg
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
#put this into prepare-commit-msg to insert branch name into commit msg | |
echo $(git symbolic-ref HEAD | awk -F/ '{print $NF}'): > $1.tmp | |
cat $1 >> $1.tmp | |
mv $1.tmp $1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment