Properly detect VCS, even if in subdir

Fixes #31