I am trying to use the following command to do a Git clone via SSH from a password-protected headless server. I am using Cygwin with OpenSSH. I can do an interactive SSH to the server without issues using Cygwin. The issue only occurs in Cygwin and not in the Windows Command Prompt.
git clone ssh://username@server.edu:path/to/repo/reponame
I do not get any sort of password prompt. I get the following error:
Cloning into 'reponame'...
ssh_askpass: exec(/usr/lib/ssh/ssh-askpass): No such file or directory
Permission denied, please try again.
ssh_askpass: exec(/usr/lib/ssh/ssh-askpass): No such file or directory
Permission denied, please try again.
ssh_askpass: exec(/usr/lib/ssh/ssh-askpass): No such file or directory
username@server.edu: Permission denied (publickey,password).
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
I am assuming this is caused by SSH and the Cygwin settings.
Unsuccessful "solutions" I have tried so far are:
Using a command of the form
git clone ssh://username:password@server.edu:path/to/repo/reponame
Entering
unset GIT_ASKPASS unset SSH_ASKPASS
and retrying the clone.
- Opening an x-forwarding server on my local machine and retrying the clone.
The solution that finally worked was opening up a Windows Command Prompt and using that instead of a Cygwin terminal. What setting in Cygwin could have caused the problem, and how do I fix it?