You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Getting Askpass for every action even when its not needed #1577
I added ssh to the ssh-agent so I don't have to constantly add the password to the sourcegit but it keeps giving me the askpass prompt for pull, push, fetch and commits.
Even when deleting branches I also get the askpass prompt.
What I find wild with deleting branches is that if you cancel the askpass prompt, the branch gets deleted either way.
If your private key has a passphrase, each time you use it, SSH will ask for its password. You can use ssh-keygen -p -f <private_key> to reset its password to empty.
and the ssh-agent is running on my terminal, however I still receive the AskPass prompt.
I even tried it out with a file creating, deleting, committing and pushing over terminal which worked without any issue.
Then the same approach with sourcegit and I still get the prompt.
Then I added this code below in ~/.ssh/config and attempted the same process again.
This time, sourcegit decided not to commit or push and simply gave me a "Permission denied (publickey)." error even though it works on the terminal. Not giving me any prompt anymore because of BatchMode yes.
I would also not take the ssh-keygen -p -f <private_key> approach since you are not keeping your SSH Key secure this way.
If this was an SSH issue then it would have also happened on the Terminal which it didn't.
I've test this on Ubuntu. After manually add keys to ssh-agent, it will not ask me for passphrase any more.
eval`ssh-agent -s`# Makes sure `ssh-agent` started
ssh-add <private_key_file># The `<private_key_file` is the same one with `SSH Private Key` of remote configuration in `SourceGit`# Then restart `SourceGit` and try to fetch/pull/push/create commit in `SourceGit`
I've no idea how to deal with this. Different users have reported different situations, and sometimes they are exactly opposite. What can be confirmed at present is that this issue behaves differently on different Linux distributions (this issue does not exist on Windows and macOS platforms).
If anyone has a solution to this problem, please feel free to submit a PR.
Is it possible to have SourceGit not do any extra work related to SSH keys (as a new option)?
I use the FIDO SSH key types (ecdsa-sk / ed25519-s). My operating system prompts me to unlock my FIDO key.
Everything works fine when I use the command line. In SourceGit I get the Askpass popup in addition to the operating system popup.
Is it possible to have SourceGit not do any extra work related to SSH keys (as a new option)?
SourceGit use these ENV to make sure there's a GUI-based ask-pass tool. It is the common way that used by many clients, such as GitHub Desktop, GitExtensions, VSCode etc.
While looking through the SourceCode I noticed that credential.helper seems to always be set to manager. Why is that?
This setting is only used for account authentication between git and the hosting platform, and is completely unrelated to this issue. The ssh process does not use this setting.
The reason is basically the same as the previous question. SourceGit needs to ensure that there is a GUI-based tool. For the Linux platform, we provide two options: git-credential-manager or git-credential-libsecret
SourceGit use these ENV to make sure there's a GUI-based ask-pass tool. It is the common way that used by many clients, such as GitHub Desktop, GitExtensions, VSCode etc.
Activity
love-linger commentedon Jul 15, 2025
This window is launched by
sshnotSourceGit:sourcegit/src/Commands/Command.cs
Lines 167 to 175 in 0a74dd6
love-linger commentedon Jul 15, 2025
Make sure you have enable the
AddKeysToAgentconfiguration in~/.ssh/configpiotr-fraczek commentedon Jul 16, 2025
Hi, I have same problem, mint, manjaro. All time when I want to do some git actions - always prompt for ssh key password
love-linger commentedon Jul 17, 2025
If your private key has a passphrase, each time you use it, SSH will ask for its password. You can use
ssh-keygen -p -f <private_key>to reset its password to empty.Akira-Kuru commentedon Jul 18, 2025
I added
and the ssh-agent is running on my terminal, however I still receive the AskPass prompt.
I even tried it out with a file creating, deleting, committing and pushing over terminal which worked without any issue.
Then the same approach with sourcegit and I still get the prompt.
Then I added this code below in
~/.ssh/configand attempted the same process again.This time, sourcegit decided not to commit or push and simply gave me a "Permission denied (publickey)." error even though it works on the terminal. Not giving me any prompt anymore because of
BatchMode yes.I would also not take the
ssh-keygen -p -f <private_key>approach since you are not keeping your SSH Key secure this way.If this was an SSH issue then it would have also happened on the Terminal which it didn't.
love-linger commentedon Jul 18, 2025
This may be because the private_key_file is passed into the SSH command every time in the code:
sourcegit/src/Commands/Command.cs
Lines 175 to 179 in 0a74dd6
Later, I'll check if there is a better way to handle the SSH connection.
love-linger commentedon Jul 21, 2025
I test this on Windows platform that when installing GIT, using external openssh (without using the built-in SSH) does not have such problems.
Makes sure
ssh-agentservice is runningBTW, on which system do you encounter this problem?
piotr-fraczek commentedon Jul 21, 2025
I use Linux: Manjaro, Mint, Ubuntu distributions
On Windows 10/11 this problem not exists :)
Akira-Kuru commentedon Jul 21, 2025
I use Linux: Archlinux & Windows 11.
This happened so far only on Archlinux but I will check Windows later today.
love-linger commentedon Jul 21, 2025
I've test this on Ubuntu. After manually add keys to
ssh-agent, it will not ask me for passphrase any more.love-linger commentedon Jul 21, 2025
I think I know why.
SourceGitfrom the terminal session that just runseval `ssh-agent -s`, this issue does not existsSourceGitfrom other terminal sessions that have not raneval `ssh-agent -s`, this issue appearsMaybe,
SSH_AGENT_PIDandSSH_AUTH_SOCKare needed by ssh command34 remaining items
Akira-Kuru commentedon Aug 14, 2025
I just tried it myself over AppImage on Archlinux and it still happens for me.
I just did a simple pull on my branch and it pops up.
love-linger commentedon Aug 27, 2025
I've no idea how to deal with this. Different users have reported different situations, and sometimes they are exactly opposite. What can be confirmed at present is that this issue behaves differently on different Linux distributions (this issue does not exist on Windows and macOS platforms).
If anyone has a solution to this problem, please feel free to submit a PR.
Doodeletion commentedon Feb 7, 2026
Is it possible to have SourceGit not do any extra work related to SSH keys (as a new option)?
I use the FIDO SSH key types (ecdsa-sk / ed25519-s). My operating system prompts me to unlock my FIDO key.
Everything works fine when I use the command line. In SourceGit I get the Askpass popup in addition to the operating system popup.
If I
uncommentcomment these lines it works.https://github.com/sourcegit-scm/sourcegit/blob/080c446ce0b24edb437dbdddd515402a0a364b0d/src/Commands/Command.cs#L176C13-L184C95
Something else:
While looking through the SourceCode I noticed that
credential.helperseems to always be set tomanager. Why is that?https://github.com/sourcegit-scm/sourcegit/blob/080c446ce0b24edb437dbdddd515402a0a364b0d/src/Commands/Command.cs#L193C1-L197C30
love-linger commentedon Feb 8, 2026
SourceGituse these ENV to make sure there's a GUI-based ask-pass tool. It is the common way that used by many clients, such asGitHub Desktop,GitExtensions,VSCodeetc.gitand the hosting platform, and is completely unrelated to this issue. Thesshprocess does not use this setting.SourceGitneeds to ensure that there is a GUI-based tool. For the Linux platform, we provide two options:git-credential-managerorgit-credential-libsecretlove-linger commentedon Feb 8, 2026
And this issue only exists on Linux platform. I do not know why.
Doodeletion commentedon Feb 8, 2026
Thanks, that makes sense.
For my specific use case, my operating system handles spawning a GUI. If you could add an option that skips the SSH setup, it would be very helpful to me. 🙏
I have tested that disabling these lines would work for my machine.
https://github.com/sourcegit-scm/sourcegit/blob/080c446ce0b24edb437dbdddd515402a0a364b0d/src/Commands/Command.cs#L176C13-L184C95
feat(ux): upstream issues から UX 改善を 6 件採用
feat(ux): upstream issues から UX 改善を 6 件採用 (#17)
love-linger commentedon Jun 3, 2026
@Doodeletion If that fixes this issue for you, you can try to clear the private key in
Edit Remotepopup.