Add Git to Development Environment

Monday, 27 January 2014, 22:57

Tags: Development Environment Setup Git VCS

Adding support for a version control system to the Development Environment is crucial. It is very important for project collaboration and it is also very convenient to have a full history of all the work you have been doing. In this post I will describe how I add Git to the development environment described in the development environment setup post.

  1. Download Git.
  2. Add a Git folder under the project root.

  3. Install Git in the new folder.
    • No additional icons, no windows explorer integration, don't create a start menu folder. I just want to setup Git for my project development environment.
    • Use git bash only. If wanted you can adapt your path in environment.bat to be able to use git from within the windows command line.
    • Use openssh only because GitHub only provides support for openssh.
    • Checkout windows-style, commit unix-style line endings.
  4. Set a GIT_HOME environment variable to the location of Git in environment.bat as shown below.

  5. Create git.bat in the environment folder to open git bash in the eclipse workspace. As shown below the bat file first navigates to the directory where git.bat resides. Next all the environment variables are loaded and the current directory is changed to the eclipse workspace. At last Git bash is opened.

  6. Add a shortcut to the shortcuts folder which runs git.bat.