Properly handle relative submodule URL paths

JGit's SubmoduleWalk tries to resolve relative submodule URLs relative
to the working tree of the repo, which fails on bare repos. JGit
should be able to handle bare file-based repos, but Gitiles is
designed to work even with non-file-based repos. So, do relative path
resolving ourselves.

While we're there, more gracefully handle the case where the submodule
URL can't be resolved for whatever reason.

Change-Id: I5e00b88e041246f8c9b0725817ca9d7345898feb
8 files changed