Add a resync command to gitshed.

This nukes existing content in your gitshed and re-fetches it from
the content store. This is useful if you have a corrupted gitshed
for some reason.

Also took this opportunity to centralize the logic of going from
a symlink to the canonical path it links to under the gitshed.

Tested manually and added unit test cases.
since the last test makes the same file this test would pass if resync was a no-op. Maybe you could change the contents of this file and then assert that the contents are reset to what they should be?