git-for-windows / git

A fork of Git containing Windows-specific patches.
http://gitforwindows.org/
Other
8.33k stars 2.53k forks source link

Cloning from GitHub shows a dialog that is not clear #4461

Open julie777 opened 1 year ago

julie777 commented 1 year ago

Setup

$ git --version --build-options

git version 2.39.2.windows.1
cpu: x86_64
built from commit: a82fa99b36ddfd643e61ed45e52abe314687df67
sizeof-long: 4
sizeof-size_t: 8
shell-path: /bin/sh
feature: fsmonitor--daemon
$ cmd.exe /c ver

Microsoft Windows [Version 10.0.19045.2965]
# One of the following:
> type "C:\Program Files\Git\etc\install-options.txt"
> type "C:\Program Files (x86)\Git\etc\install-options.txt"
> type "%USERPROFILE%\AppData\Local\Programs\Git\etc\install-options.txt"
> type "$env:USERPROFILE\AppData\Local\Programs\Git\etc\install-options.txt"
$ cat /etc/install-options.txt

Editor Option: VIM
Custom Editor Path:
Default Branch Option: main
Path Option: CmdTools
SSH Option: ExternalOpenSSH
Tortoise Option: false
CURL Option: OpenSSL
CRLF Option: LFOnly
Bash Terminal Option: MinTTY
Git Pull Behavior Option: Merge
Use Credential Manager: Enabled
Performance Tweaks FSCache: Enabled
Enable Symlinks: Disabled
Enable Pseudo Console Support: Disabled
Enable FSMonitor: Disabled

insert your response here

Details

Git Bash

git clone git@github.com:...

clone the repo

rimrul commented 1 year ago

Ah, I see what's happening. When we wrote git-askpass we didn't quite expect the questions that OpenSSH would ask to be this long. The prompt from OpenSSH gets cut of at the input field. The full uncropped prompt seems to continue with

Are you sure you want to continue connecting (yes/no)?

So the underlying ssh is expecting you to enter either yes or no in there.

dscho commented 1 year ago

As to the concrete problem pointed out by the error message, and how to deal with it, see https://github.blog/2023-03-23-we-updated-our-rsa-ssh-host-key/

rimrul commented 1 year ago

screenshot of git-askpass.exe

I've made some progress with resizing the dialog according to the length of the prompt, now I just need to figure out why the pushbuttons are behaving the way they are.