Am I using Git in Eclipse correctly?

Using Eclipse Juno on Windows. After battling Git a bit, this is what I came up with:

Note. At this point, I want to be able to push to GitHub.

  • Configure project
  • Put it under version control
  • Create a remote which is my GitHub repository
  • Press on the remote

However, I want to make it so that whenever I commit a transaction in Eclipse, it will automatically update my GitHub repository. It currently only updates my local folders. Do I make sense? How should I do it?

Also why is it bad practice to use Git in the Eclipse workspace? My directory structure looks like this on my local machine:

  • ... workspace / ProjectName
  • ... workspace /ProjectName/.git
  • ... workspace / projectname / bin
  • ... workspace / ProjectName / cci

Thank!

PS If this sounds really noob, yes, I'm pretty new to version control, but I figured I needed to start somewhere. Looked at all the tutorials online and this is what I came up with.

+3


source to share


1 answer


Automatic pushing changes on the remote control.

The latest version of the eGit plugin for Eclipse has a checkbox that will push each commit to the configured remote.

People from CVS / SVN usually click on the remote automatically. However, in a distributed version control system like Git, I would suggest doing this. Especially in larger teams, you don't necessarily want to push every commit to the remote for everyone to see.



Directory structure

There is an entry on why Eclipse advises not to create a repository in the Eclipse workspace.

+2


source







All Articles