diff --git a/git/.aspell.en_US.per b/git/.aspell.en_US.per new file mode 100644 index 0000000..e714e3a --- /dev/null +++ b/git/.aspell.en_US.per @@ -0,0 +1,5 @@ +personal_ws-1.1 en 0 +FAXM +BLOT +Lakos +Vundle diff --git a/git/hooks/commit-msg b/git/hooks/commit-msg index 28e5f1f..afbff24 100755 --- a/git/hooks/commit-msg +++ b/git/hooks/commit-msg @@ -32,11 +32,13 @@ # 3. Move this file into your repository # $ mv commit-msg /path/to/repo/.git/hooks # $ chmod +x /path/to/repo/.git/hooks/commit-msg -# -CHECK=$(cat $1 | hunspell -d en_US -l) +CHECK=$(cat $1 | aspell --lang=en_US list --add-extra-dicts=$HOME/.aspell.en_US.per) +#CHECK=$(cat $1 | hunspell -s -d en_US,${HOME}/devel/scripts/git/my_dictionary -l) if [ "${CHECK}" != "" ]; then - echo "Spell Check Error: ${CHECK}" - echo "Message: $(cat $1)" + echo "Spell Check Error:" + #cat $1 | hunspell -a -d en_US,${HOME}/devel/scripts/git/my_dictionary -l + cat $1 | aspell -a --lang=en_US list --add-extra-dicts=$HOME/.aspell.en_US.per + echo "Use --no-verify if you want to commit." exit 1 fi