For platform downloads, support git cloning in addition to gitweb snapshots.

I found that the http(s) URLs in platforms.js will always get a
suffix appended, which will fetch the snapshot of a certain tag
from the gitweb instance at the given URL. This is impractical
if trying out changes in personal platform branches that don't
have an associated gitweb server, such as GitHub, GitLab
or even local repositories for testing purposes.

@jsoref suggested to implement support for cloning from pure
git repositories in addition to the current snapshot fetching
mechanism. This patch is pre-screened by him (except for the
part where I pass size to onSuccess, because I only discovered
later that that was missing in the git code path. Rather than
passing a random value we don't have or reconstructing such
from the final directory size on disk, I thought it would be better
just to pass 0 because we don't know how big the download was).

=== Start of commit message ===
To use this, prefix the URL in platforms.js with a git protocol.
git:// is accepted as is, others go by the common convention of
having "git+" prefixed to the actual URL. So we end up with
git+ssh://, git+http[s]://, git+ftp[s]://, git+rsync:// and
git+file:// for git URLs that you want to clone.

(The common form git@host.xz:path/to/repo.git is also an SSH URL,
see git help clone for details.)