Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,359,851
Community Members
 
Community Events
168
Community Groups

How to configure Sourcetree to use Windows SSH

I'm using Sourcetree with system Git on windows with the windows OpenSSL feature enabled. I've created a ssh key successfully in the command prompt and added it to git. The commandline remembers my SSH passprhase and I can successfully clone a repository with SSH.

Now, when I run sourcetree it asks for the SSH passphrase, regardless of the ssh config in my global .gitconfig, which sourcetree should about I'm guessing.
My SSH client in sourcetree is set to OpenSSH and I have no SSH Key configured there.
My guess is that sourcetree is still trying to use the ssh in git as it tries to lauch the ssh agent (peagant) which aks for my passprase. Running git from the commandline never asks my passphrase as the Windows Credentials manager knows it and automatically enters it AFIK.

What do I need to change in sourcetree config to get this working?

I've got ` sshCommand = "C:/Windows/System32/OpenSSH/ssh.exe"` in the `.gitconfig` `[core]`-section.

Sourcetree 2.6.10.0

Microsoft Windows [Version 10.0.17134.285

Git 2.19.0

1 answer

I'm pretty sure sourcetree is still trying to use the Git SSH from my system git installation and that's the reason why it asks for the SSH passphrase all the time.

That means Sourcetree completely ignores the sshCommand entry in my global gitconfig. When I replace the ssh.exe and other ssh executables in the system Git folder with thosse of the Windows OpenSSL feature and start sourcetree again it doesn't complain about the SSH passphrase and I can push and pull successfully with SSH.

Based on this I'm pretty sure the problem is that Sourcetree ignores (part) of the global gitconfig and provides no method of specifying the sshCommand to use.

Suggest an answer

Log in or Sign up to answer
TAGS
Community showcase
Published in Sourcetree

Bug Fix: Sourcetree for Windows authentication error when updating to app password

Hello Sourcetree users!!! With the recent removal of Bitbucket Cloud account passwords for app passwords (please see our Bitbucket Cloud community post for details on why we made this change for se...

78,667 views 134 29
Read article

Atlassian Community Events