Skip to content

Instantly share code, notes, and snippets.

View shotasenga's full-sized avatar

Shota Senga shotasenga

  • Canada
View GitHub Profile
@shotasenga
shotasenga / pre-commit
Created September 14, 2013 02:43
Git pre-commit hook. user.name, user.email がローカルにセットされていなければコミットさせない。
#!/bin/sh
## fork from http://qiita.com/uasi/items/a340bb487ec07caac799
if [ -z "`git config --local user.name`" ]; then
echo "fatal: user.name is not set locally"
exit 1
fi
if [ -z "`git config --local user.email`" ]; then
echo "fatal: user.email is not set locally"
exit 1