Move git describe into method.

Use --git-dir instead of chdir.
Ignore OSError in case git is not installed.