Factor/Contributing/Git Repository Setup
Where to get Git space
See the FAQ.
Contact Daniel Ehrenberg (firstname.lastname@example.org) to get an account on http://factorforge.org. Even the most trivial contributions get space here! Ask him for further directions if the ones below are insufficient.
How to publish a Git repository
To set up a repository on a server you should clone the existing Factor repository using the '--bare' option:
git clone --bare git://factorcode.org/git/factor.git factor.git
A bare repository is one without a checked out working copy of the code. It only contains the git database. As a general rule you should never push into a repository that contains changes in the working copy. To ensure this doesn't happen, we're making the server repository a bare repository - it has no working copy.
Copy the 'factor.git' directory onto your server. I put it in '
git push email@example.com:/git/factor.git
If you want to push changes from a specific branch in your local repository:
git push firstname.lastname@example.org:/git/factor.git mybranch:master
To publish the remote repository you have two options. You can publish via the HTTP protocol, or via the git protocol. The first is slower but usable by people behind restrictive firewalls, while the second is more efficient but requires an open port. I suggest doing both.
To publish via HTTP, you must make the file '
chmod +x /git/factor.git/hooks/post-update
This gets executed whenever something is pushed to the repository. It runs a command '
cd /git/factor.git git-update-server-info
Now make the
git pull http://yourserver.com/git/factor.git
To set up the git protocol you need to run the '
Run the daemon with:
git-daemon --verbose /git
git pull git://yourserver.com/git/factor.git
git clone http://factorcode.org/git/factor.git git clone git://factorcode.org/git/factor.git
You can also browse it using gitweb.
Article originally from Chris Double at http://www.bluishcoder.co.nz/2007/09/how-to-publish-git-repository.html
This revision created on Sun, 12 Jul 2009 19:07:55 by mncharity (+link to FAQ)
All content is © 2008-2010 by its respective authors. By adding content to this wiki, you agree to release it under the BSD license.