ssh - Why git under cygwin asks for password? -
i correctly pointed key file in ssh config:
$ cat ~/.ssh/config host <host> identityfile /cygdrive/v/poma.pem $ ssh git@<host> pty allocation request failed on channel 0 welcome gitlab, roman! connection <host> closed.
and using cygwin's git
$ git /usr/bin/git $ git --version git version 2.1.4 $ /cygdrive/c/program\ files\ \(x86\)/git/bin/git.exe --version git version 1.9.5.msysgit.1
but when try push displays password prompt:
$ git remote -v origin git@<host>:poma/deploy.git (fetch) origin git@<host>:poma/deploy.git (push) $ git push -u origin master fatal: not read remote repository. please make sure have correct access rights , repository exists.
why happening?
as workaround, try doing same setup (~/.ssh/config) on windows (no cygwin, latest git-for-windows (unzip anywhere want portablegit-2.4.4.2-3rd-release-candidate-64-bit.7z.exe
, , got git 2.4.4: see more here)
by using git-cmd.exe (or git-bash.exe), environment home has been set %userprofile%
.
in it, put .ssh/config file, , try again pushing repo.
Comments
Post a Comment