Open arxanas opened 2 years ago
You might consider #574
So, in my opinion, sync should not fetch, should not have network activities involved. It should just automatically move all my working commit to a dest.
pull
is an extremely easy command, un-pull
is not! So just handle the control back to user will solve all your headache.
My workaround is to do the following before a command which runs git fetch
:
In my case, I use ssh-agent and ssh-add -K /path/to/key (on macOS) to unlock the key, and then git sync --pull works for me. Does that workaround work for you?
Description of the bug
This happens when we're being prompted interactively for a password e.g. to authenticate with Github over HTTPS. Askpass-style programs do not read stdin/write stdout, so https://github.com/arxanas/git-branchless/pull/429 doesn't help. Instead, they directly read/write to the terminal (so that the password is hidden).
Furthermore, if the askpass program fails, it seems that Git falls back to prompting on the terminal manually, so there's no way to cancel asking for the password. For example, even when
exit 1
ing:Expected behavior
Either the password is prompted or the operation fails immediately.
Actual behavior
Hangs forever.
Version of
rustc
No response
Automated bug report
No response
Version of
git-branchless
No response
Version of
git
No response