Using EGit to Push Local Eclipse Repositories to Github
EGit is an Eclipse Team provider for the Git version control system. Using EGit a developer can push a local Eclipse repository to GitHub.
First create a new repository at GitHub:
Your new repository will have a clone URL:
In Eclipse, open “Window” > “Preferences”:
-make sure that your SSH2 home is configured correctly
-make sure that your SSH2 home contains your SSH2 keys
-make sure that you have saved your public key to your GitHub account settings
If you have not yet generated a SSH key, click the “Key Management” tab to generate a new public key.
-Remember to save this new key to your GitHub account.
Select your Eclipse project and click “Team” > “Push To”
-Enter your GitHub clone URL
-Enter your GitHub password
-Enter “git” as the user
Accept the connection:
Enter the password associated with the SSH key:
Enter “refs/heads/master” as source ref and destination ref
Click “Add all branches spec”
Click “Next” and then “Finish” to confirm the push:
Your GitHub repository has been updated: