For the time being I'm disabling the Staging View in Windows > Preferences> Team > Git > Committing, opting to use the old-fashioned Commit Dialog (the one from Eclipse Mars) instead. I don't have time to muck around with extra listbox selections, mouse clicks, and context menu selections just to commit my code.
I hope someone else comes up with a better answer. The Git Staging View was interesting... but not if it slows me down.
Answer from Garret Wilson on Stack OverflowVideos
For the time being I'm disabling the Staging View in Windows > Preferences> Team > Git > Committing, opting to use the old-fashioned Commit Dialog (the one from Eclipse Mars) instead. I don't have time to muck around with extra listbox selections, mouse clicks, and context menu selections just to commit my code.
I hope someone else comes up with a better answer. The Git Staging View was interesting... but not if it slows me down.
Select YourProject --> Team --> Commit..., A Git Staging console will open.
Now follow below steps for Commit or Commit and Push changes...
There are two ways to add files in Staged Changes:
- drag and drop the corresponding tree node to the staged changes pane.
- click "Add to Git Index" from the context menu.

- click "Add to Git Index" from the context menu.
- drag and drop the corresponding tree node to the staged changes pane.
Enter the commit message.

- Click "Commit" or "Commit & Push"
I am not expert but i have done this once
think simple and straight way is
1.Download Git to your system
2.cd to your eclipse prject cd /workspace/sampleproject
3.Commands
git config --global user.name "Your Name Here"
git config --global user.email "[email protected]"
touch README.md
git init
git add README.md
git commit -m "first commit"
git remote add origin https://github.com/gitusername/reposname.git
git push -u origin master this line may throw an error but no problem
4.From eclipse ->Help->eclipse marketplace ->search for 'git' -> install 'Egit-git team provider'
5.Go to eclipse ->Windows ->Open perspective ->Git repository
6.From Git repository view on the left side on 'Add existing local repos' then browse to '/workspace/sampleproject'
7.Now Right click on this added Repository location and add comments press Commit.
8.Now Right click on this added Repository click Push
By default Configured remote repository should be checked then press Next
From Source Ref and Destination Ref Select HEAD //you may change if u want
Select next give your github username and password then click on Finish.
If you are using the https address, you need to pass your credential (Github login and password).
See "Syncing with github" for an example.
With Eclipse and Egit, you can set those credential when defining a remote address for your local repo.
See "Push upstream".
