index f2a3615bbc44ed4edbee4014683621a91c1a7ab9..119cff98597f6539e88327bcafaa0bd5a88c020e 100755 (executable)
git rev-parse --git-dir 2>/dev/null) ||
die "\"$orig_git\" is not a git repository!"
+case "$git_dir" in
+.git)
+ git_dir="$orig_git/.git"
+ ;;
+.)
+ git_dir=$orig_git
+ ;;
+esac
+
# don't link to a workdir
if test -L "$git_dir/config"
then