ssh ignores current users .ssh folder
To keep track of multiple accounts a custom ssh configuration is uesd with sample
Host github.com
HostName github.com
User git
IdentityFile ~/.ssh/id_ed25519_normal
Host github-special.com
HostName github.com
User git
IdentityFile ~/.ssh/id_ed25519_special
pull-request-github complaints about connection [email protected];user/repo.git
Can you give an example of the complaint?
Login not possible
I don't see the error "Login not possible" anywhere in this extension code base or microsoft/vscode. Can you share a screenshot?
the complete text:
Fetching pull requests for remote 'origin' failed, please check if the url [email protected]:theking2/dwh_php7.git is valid.
Integrated source control has no problem.
git remote --verbose
proj1 https://github.com/theking2/proj1.git (fetch)
proj1 https://github.com/theking2/proj1.git (push)
origin [email protected]:theking2/proj1.git (fetch)
origin [email protected]:theking2/proj1.git (push)
config in (-join($Env:USERPROFILE)) /.ssh:
#theking2 account [email protected]:theking2/repo-name
Host github-special.com
HostName github.com
User git
IdentityFile ~/.ssh/id_ed25519
I'm not sure this is the exact same issue, but may be in a similar vein...
I have multiple GitHub accounts I use (Personal & Work). When logged in to the extension with my personal GH account and try to access a work repo I get the error: Fetching pull requests for remote 'origin' failed, please check if the url git@my-org/work-repo.git is valid.
Is there a way to login to GitHub PR Extension with more than one GitHub account? Or configure it to accept different credentials for different repos?
@DirtySoc it is possible to work with mulitple github accounts exactly in the way I described. If I clone from my 'normal' account I use:
git clone [email protected]:user1/proj1.git
if I clone from my special account I use:
[email protected]:user2/proj2.git
This works in Source Controlin vscode as:
git remote --verbose
origin [email protected]:user2/proj2.git (fetch)
origin [email protected]:user2/proj2.git (push)
Unfortunately Pull Requests ignores the settins in .ssh/config and always uses a fixed github.com ([email protected]:user2/proj2.git).
I also have the same issue, I use multiple accounts one personal and another one for work, I clone using my personal. account by adding -personal to [email protected]:xxxx/xxxx.git and it becomes [email protected]:xxxx/xxxx.git.
apparently the extension doesn't support that and as a result I get the same error message
Fetching pull requests for remote 'origin' failed, please check if the url [email protected]:xxxx/xxxxx.git is valid.
please have a look at this.
Should be a duplicate of https://github.com/microsoft/vscode-pull-request-github/issues/3329 and the problem fixed by https://github.com/microsoft/vscode-pull-request-github/pull/3946.
If you're interested in trying out the fixes, please use the pre-release build (starting with the one that will be released tomorrow) and the latest VS Code Insiders. There is also PAT-less auth there.