I\'ve installed EGit plugin at Eclipse Helios and I\'m trying to use it with my GitHub account, but when I try to configure it I get an \"Auth Failed\" error.
I\'d b
I resolved it by selecting https as the protocol and then adding my github username and password
I found a post on the Eclipse forums that solved this problem for me.
I had exactly same problem but I found the cure from a Eclipse bug report!
An environment variable named GIT_SSH must be set with a path to a ssh executable [1].
For example on Ubuntu Linux (10.10 64bit):
> export GIT_SSH=/usr/bin/ssh
> eclipse
After that pushes to GitHub repository work like they should. I tested this with Eclipse Galileo and Indigo.
The problem is really annoying and the solution is far from nice. For now, making the solution permanent for, at least Ubuntu users, one must make the env variable permanent. It can be done by adding the export command to ~/.profile or ~/.bashrc [2]. For example:
> cd ~
> echo "export GIT_SSH=/usr/bin/ssh" >> .profile
And then restart Eclipse to take effect.
Sources:
In your GIT view where you have your repositories you will see a structure such as:
Click on remotes, right-click on the url of the repository there and select 'Change Credentials'.
For you who, like me, already did setup you ssh-keys but still get the errors:
Make sure you did setup a push remote. It worked for me when I got both the Cannot get remote repository refs-problems ("... Passphrase for..." and "Auth fail" in the "Push..." dialog).
Provided that you already:
Setup your SSH keys with Github (Window > Preferences > General > Network Connections > SSH2)
Setup your local repository (you can follow this guide for that)
Created a Github repository (same guide)
... here's how you do it:
I could use console to push/pull the repositories, but no in eclipse. In my case, eclipse seems can't read my SSH private key, my key started with:
-----BEGIN OPENSSH PRIVATE KEY-----
And I noticed my colleague's key started with:
-----BEGIN RSA PRIVATE KEY-----
Proc-Type: 4,ENCRYPTED
I think currently eclipse can't take this new kind of key (OPENSSH PRIVATE KEY).
I solved it by: Regenerate your ssh key by using command:
ssh-keygen -m PEM -t rsa -b 2048
This will use the old way to generate the key: so it will starts with the headers:
-----BEGIN RSA PRIVATE KEY-----
Proc-Type: 4,ENCRYPTED
see more information on:
https://github.com/duplicati/duplicati/issues/3360
Then you can load the key again in eclilpse by using Preferences -> Network connections -> SSH2, click "Add Private Key" (still select your private key, even you already see the name in the list of private keys, because eclipse has to reload it)