How to change port in GIT

When you clone repository from git using SSH you may get following error message

ssh: connect to host github.com port 22: Bad file number 
ssh: connect to host (some host or IP address) port 22: Bad file number

Solution :

Step 1: open gitbash
Step 2: > touch ~/.ssh/config
Step 3: > Paste following code in config file

Host github.com
   User git
   Hostname ssh.github.com
   PreferredAuthentications publickey
   IdentityFile ~/.ssh/id_rsa
   Port 443