I am trying to figure out the best way to create a java project in GIT. In particular I would like to create the git repository such that when I import from git in eclipse, the project is automatically created correctly with all its .project settings intact and all other settings setup. I.E. if I do a git clone javaEclipseProject in my workspace/ folder then do an import on that javaEclipseProject folder it will open up the project without having to use the new project wizard.
I'm sure you could do that....but I know even in the company I work for, .project files are not portable from one machine to another. If you get your project building in either Ant or Maven then check it in, Eclipse, Netbeans and/or IntelliJ will be able to check out the project and build their own .project files from your start.
Moving on to the more....shall we say "religious" aspects of the problem, personally I like the way Maven or Ivy or "insert many other Ant++ build tools here" will go ahead and find any dependencies that you might not have already and download them for you. I'm sad to say, but in the times I've used them, Eclipse actually has the least easy to use Maven support though, I don't use IntelliJ, but the snobs.....I mean co-workers I have that do say integration is seamless, and Netbeans it just flawless for Maven.
YMMV of course.
Add the dot-files (.project, .classpath and the .settings directory) to the Git repository. That is what we do with the Git plugin itself.