Skip to content

Comment on Three locks for your SSH doorparent

Comments

On Mac/Linux, setting a different default port for your host in ~/.ssh/config will allow git and other applications to automatically use the new port binding on the server.

My ~/.ssh/config basically looks like https://gist.github.com/78ec014f31c8a06f656b

…which allows me to just use "ssh server1.example.com" and "git clone foo@server1.example.com:blah/project" to access those resources without explicitly defining the port number.

---

Edit: The standard msysgit installer for Windows may look in the same place too — I haven't tried.

Ah that's very useful. Thanks.

I only recently realized I could abbreviate hostnames in .ssh/config.

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.