Distributed Version Control system

From CSU-CHILL

Revision as of 20:38, 11 August 2009 by Jgeorge (talk | contribs) (Added article about Git access)

The CHILL facility now uses the distributed version control system, Git.[1][2], we have switched over from using the legacy CVS [3] system.

We maintain a master repository at the CHILL site, which retains the "golden" copy of the code base. Users may clone this repository and work independently, and those with write access can push their changes back to the master repository. In order to comply with CSU IP policy, anonymous access to the git repository is not enabled, you must have an account to use the system.

The following guide to accessing the repository assumes a Linux machine.

Creating an account

Generate an ssh key for the machine from which you would like to access the CHILL Git repository.

ssh-keygen

Accept the defaults to all the questions asked, and you should have a file called ~/.ssh/id_rsa with your private key and ~/.ssh/id_rsa.pub with your public key. Copy the public key to some convenient location, then rename it to username.pub

cp ~/.ssh/id_rsa.pub ~/jgeorge.pub

Of course, use your own user name here. It is not necessary to use exactly the same user name as your local login, but it helps us distinguish one key from another.

You can then email the public key to David Brunkow or Jim George, and we will add you to the list of git users. Please include a short description of why you want access to the repository as well. You can obtain email information from the Contacts page.

Cloning the repository

Once you have been registered with the git system, you can create a clone of the repository. First, you need to modify your ssh setup to use a different port when contacting the CHILL servers, this is a security measure. Edit the ~/.ssh/config file. Create one if it doesn't exist, and add the following lines:

Host git.chill.colostate.edu
        Port 20789

Now, you can clone the repository using:

git clone gitosis@git.chill.colostate.edu:cdp.git

The cloned repository will also have a working copy that you can edit and compile.

More information about git may be found in the git tutorial.

External Links

References