I knew for a fact this feature existed, but even so it took me a half hour to track down the syntax for it. To prevent myself ever needing to do that again, I’m putting it here. To create a nice, short URL abbreviation for git, such as myserver:project.git, put the following in ~/.gitconfig
[url "ssh://my.server/~/"]
insteadOf = myserver: