create git repo and connect using eclipse

In order to keep my software developments in line and keep access also from remote sides I decided to use git on one of my servers and use eclipse for the development itself. So to add or create a new repository I follow this steps:

– create new directory: mkdir <repo>

For convenience I use a naming as: repo-<section>-<subsection> (e.g. repo-php-project)

– change to the newly craeted directory: cd <repo>

– initailize a bare git repo: git init –bare

This will fill in a repo with the administrative stuff inside but without any further details. Those will come with the first clone/commit.

– clone the empty repo from within eclipse using the import function: Project perspective -> Import -> Git repository -> New Project

This will create a new project within eclipse based on the newly created git repo.