Issue
I try to upload a file via ssh to my server:
scp -p 2222 user@myhost:/Users/myuser/mypage/myrepository.git
I get the error message:
How do I specify scp to use port 2222?
Solution
This worked for me:
scp -P 2222 -r myrepository.git user@myhost:/Users/myuser/mypage/
Answered By - peace_love Answer Checked By - Dawn Plyler (WPSolving Volunteer)