MDLSITE-3645 support diff urls when we can..

This change adds support so that we can link to git diffs magically for people using:

* github
* bitbucket
* gitorious

I am sending this for initial review - the placement of the logic is not exactly perfect in this tool, but I think it sort of makes sense.