mhutchie / vscode-git-graph

View a Git Graph of your repository in Visual Studio Code, and easily perform Git actions from the graph.
https://marketplace.visualstudio.com/items?itemName=mhutchie.git-graph
Other
1.97k stars 261 forks source link

Missing flow for fetching from remotes when user has a SSH passphrase linked to GitHub account #755

Open arthurbrndao opened 1 year ago

arthurbrndao commented 1 year ago

Describe the Bug Fetching from remotes when clicking on the upper-right fetch icon and the user has a SSH passphrase linked to his GitHub account throws a "Permission denied" error because of the missing flow for typing a passphrase.

Steps to Reproduce Steps to reproduce the behaviour:

  1. Link a SSH key with a passphrase to your GitHub account.
  2. Click on the upper-right fetch icon.
  3. See error.

Expected Behaviour A clear and concise description of what you expected to happen.

Environment

Screenshots (optional) image

How I think it should look! VSCode has a nice way to deal with it. That's how it look like: image

Additional Context (optional) Bug only occurs when user has a SSH passphrase linked to a GitHub account.

⚠ Please make sure you complete all of the required sections of this template. Without this required information, it will be harder to replicate this bug, and cause additional delays in resolving it.

edwardjamesgaff commented 1 year ago

FYI the workaround from https://github.com/mhutchie/vscode-git-graph/issues/246#issuecomment-1298541217 currently works for me:

Just add those keys bellow to your environment:

DISPLAY=needs-to-be-defined
SSH_ASKPASS=/mingw64/libexec/git-core/git-gui--askpass

Source: https://github.com/microsoft/vscode/issues/13680#issuecomment-575204695_

After settings those 2 env vars, the 'Fetch' button prompts for a password.

But if Git Graph handled it the same way as VSCode and I didn't have to remember to add those env vars that would be great!