setup-hooks.sh 258 Bytes
Newer Older
1 2 3 4 5 6 7 8 9 10
#!/bin/sh

curr_dir="$(pwd)"
target_file=${curr_dir}/.git/hooks/pre-commit
source_file=${curr_dir}/.git-hooks/pre-commit
if [ -f $target_file ]; then
   echo "Please move current $target_file out of the way first."
else
   ln -s $source_file $target_file
fi