Hosting documentation/Subversion

From Bioinformatics.Org Wiki

< Hosting documentation
Revision as of 22:37, 24 March 2008 by Cody (Talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Anonymous Subversion access

Anonymous Subversion access uses svnserve and does not require SSH.

$ svn checkout svn://[/module] [directory]

Note that you do not need to specify the destination directory. If you are checking out a repository named "bioworks", for example, you could change to the directory where you want the repository to be placed, and then type the following:

$ svn checkout svn://

Subversion cleints

If you are using a Unix-variant, Subversion clients are easy to find or may already be installed on your system. Simply type svn to see if you have one.

For Windows, TortoiseSVN is one of the best clients and highly recommended.

Plus, Bioinformatics.Org has a Web interface for browsing and downloading source code from Subversion.

Developer access

For all developer (read/write) access, you will be using SSH (Secure Shell). The SSH (2.x or better) client must be available to your local machine. Note that you will need to type in your password for each command, unless you use ssh-agent with SSH keys. SecurityFocus has articles on generating SSH keys and setting up ssh-agent.

Creating a repository as a developer

This part requires shell access.

1. Change your primary group affiliation to "svn" using the newgrp command (explanation).

2. Use the "FSFS" filesystem type (explanation).

$ newgrp svn
$ svnadmin create --fs-type fsfs /svnroot/repository

If you are creating a new repository named "bioworks", for example, you would type the following:

$ newgrp svn
$ svnadmin create --fs-type fsfs /svnroot/bioworks

The next set of Subversion commands can be run from your local machine, and they will have the following form:

$ svn command svn+ssh://

Importing source code into a Subversion repository as a developer

$ svn import module/ svn+ssh://[/module] -m 'message about import'

If, for example, your username is "jdoe", and you are importing a new module named "trunk" into the repository named "bioworks", you would type the following:

$ svn import bioworks/ svn+ssh:// -m 'Initial import.'

Conventional repositories contain trunk, branches and tags modules at the root level.

Initial checkout and other commands as a developer

$ svn checkout svn+ssh://[/module] [directory]
$ svn update
$ svn add filename
$ svn delete filename
$ svn commit

Additional references

Personal tools
wiki navigation