Setting up a remote git repository

Category: By AG
Just for reference.

1. Download git sources
Grab the latest tarball from http://www.kernel.org/pub/software/scm/git/

2. Extract and do make prefix=. I usually install such things in ~/bin

3. Make sure git binaries are in your PATH

4. 'cd' to the directory you want to start the project in, be it empty or already filled with project source files. Do 'git init-db'. It will respond with "defaulting to local storage area."

5. Run 'git add .', which adds the files in the current directory recursively. If you want to add a subset of files, specify them explicitly.

6. Run 'git-daemon' as appropriate. Use may want to use 'screen' if it doesn't have the --detach option. See http://www.kernel.org/pub/software/scm/git/docs/git-daemon.html

7. Test the setup by executing this or a similar command on a different machine "git clone git://server/git/project"

Alternatively, tools like cogito can also be used which "ease" the use of git. Cogito can be found here: http://www.kernel.org/pub/software/scm/cogito/

That is all :) Happy Hacking!

2 comments so far.

  1. Abhijit Deodhar 9:08 PM, August 01, 2006
    why do open source guys keep changing the version control systems?
  2. AG 7:18 AM, August 02, 2006
    git is here to stay for a long time to come...in fact it was yembarrasing when linux kernel crew used a proprietary SCM bitkeeper - which was scrapped following a long discussion. And then the big tux himself sat down and wrote git for his project :) Cool, isn't it? Both git and Linus.

Something to say?