Respect the GIT_DIR environment variable

We now use the value of the GIT_DIR environment variable when searching
for the Git repository.

Closes #13.