Deal with opening relative paths when not at the top level of the repo.

Before if you were in say lib/ and opened foo in there, it would open it
as if it were /foo not /lib/foo.