#!/bin/sh

cp ./tools/git-hooks/* .git/hooks &> /dev/null \
  && echo Git hooks installed. || echo Git hooks NOT installed.

#!/bin/bash

cd "$( dirname "${BASH_SOURCE[0]}" )"

if [ -d ../.git/hooks ]; then
  cp git-hooks/* ../.git/hooks/
  echo Git hooks installed.
else
  echo Git hooks NOT installed.
fi

Make the git hooks install script more reliable
Make the git hooks install script more reliable

- it can now be run from anywhere,
- it checks for the existence of the `.git` folder rather than trying to write
  to it and handling failure with `||`.
