Just a reminder, suppose your ssh port is 3022: (sometimes I swap the way to specify the port in those two commands)

git clone ssh://user@domain.com:3022/~/Projects/my_project

ssh user@domain.com -p 3022
(when connecting through ssh the non default port goes as param, the default port is 22)

You can also add the host to your ~/ssh/config so you don’t need to add the port every time you use ssh/git:
Host *example.com
Port 3022