We are in the process of migrating all new development to a git-based version control system. The main driver is the ability to check changes into a local database before the changes are fully tested and ready for the central server. Once the changes are ready, then we can push to the central server for everyone to use.
I basically used this link…
I’ve copy/pasted the important parts to ensure it doesn’t disappear.
install git server
$ cd /usr/port/devel/git
$ make install clean
git_daemon_flags=”–export-all –syslog –enable=receive-pack –listen=ip_address –verbose ”
add user – git
$ pw user add git
$ passwd git
start git daemon
$ /usr/local/etc/rc.d/git_daemon start
build local repository
$ mkdir /path/to/repo/mydroid.git
$ cd /path/to/repo/mydroid.git
$ git –bare init
$ chown -R git mydroid.git
$ chgrp -R git mydroid.git
I found through trial and error that that repository must be created on the server using the git –bare init command.
Once I had the server installed and running, I turned to configuring my gui client, Smart Git. I recommend both Smart Git and Smart SVN. They are terrific guis to assist in the adoption of version control systems. One hassle with Smart Git, was the undocumented requirement to use SSH keys for connecting to the server. The URL I used was an ssh url, but I thought it could do password authentication. Once I figured out to transfer my public key to the server’s user ssh directory, things connected nicely.