Uploaded image for project: 'Sourcetree for Windows'
  1. Sourcetree for Windows
  2. SRCTREEWIN-8516

SSH-Agent is not available from Git-Bash terminal

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • Low
    • None
    • 2.5.3-beta-0, 2.5.4-beta-0
    • None
    • Severity 3 - Minor

    Description

      The connection to my remote in Bitbucket uses the SSH protocol. Using Sourcetree to push, pull, and fetch works as expected and without issues.

      The problem occurs when I start Git Bash using the Terminal button in Sourcetree. If I try to use any of the remote-related commands like `git push`, `git pull`, or `git fetch` then I get prompted for my key's passphrase. The annoying part is that this happens every time I use any of those commands, regardless of whether I am still in the same Git Bash session, or if the Git Bash window was closed and reopened, or if I used the command only a few seconds ago.

      I would understand if the key is loaded — and I get asked for the passphrase — the first time I use a remote-related command for that session of Git Bash, but if I don't close the Git Bash window, being asked for the passphrase for every command is bothersome. Is it possible to keep the key loaded for that session of Git Bash?

      PS: I've been able to associate Sourcetree's ssh-agent with a Git Bash session, and keeping the key loaded, but only if the Git Bash window wasn't started from the Terminal button in Sourcetree. I do this by manually (or with a script) setting the SSH_AUTH_SOCK and SSH_AGENT_PID variables accordingly. But for some reason, this doesn't work if I try to do it with the Git Bash session started with the Sourcetree Terminal button.

      Attachments

        Activity

          People

            Unassigned Unassigned
            mminns minnsey
            Votes:
            3 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated: