In the interests of security, SourceForge does all its communication with logged-in users over secure encrypted channels. This is the case even for the web-based services. There are two important utilities that cannot be accessed via a web interface, but instead by using ssh, the secure shell. These utilities are the shell server and CVS.
Note: Debian-specific |
# apt-get install ssh |
There are two versions of ssh available in Debian. As of the Woody release (Debian 3.0), ssh is included in the main distribution but ssh2 is only available under the non-free section. For our purposes, normal ssh is perfectly fine.
The shell server provides command line access to the SourceForge system.
Login via
$ ssh username@shell1.sourceforge.net |
CVS is used to organize and store collections of files in a central repository, so that many developers can work on them at once. More than one developer can work on the same file at a time. If one change conflicts with somebody else's change, CVS will warn the second user and attempt to solve the problem.
Before using CVS with SourceForge you need to make sure the environment variable CVS_RSH is set to `ssh'. For bash you can set it like this:
$ export CVS_RSH=ssh |
You can add this to your ~/.bashrc to have the variable set it every shell.
First of all you must check out a working copy of the repository. This contains all the newbieDoc source files. Go to the directory in which you wish your local copy to be kept, e.g. ~/cvs.
$ mkdir ~/cvs $ cd ~/cvs |
To check out a working copy, issue the command
$ cvs -d:ext:username@cvs.newbiedoc.sourceforge.net:/cvsroot/newbiedoc checkout newbiedoc |
If you make changes to a file already in the repository you will need to `commit' them so that the changes can be seen by everyone in the project and become the official copy of the file.
$ cd ~/cvs $ cvs commit -m 'comments for this commit' filename |
Alternatively, you can omit the -m argument ($ cvs commit filename). Your preferred editor, as specified in the EDITOR environment variable, will appear for you to note your changes. The commit will then continue once the file is saved.
Your comments can be a short note, summarizing your changes.
Another useful option for committing files is '-r', which forces a particular version to be assigned to the file, regardless of what CVS might automatically want to assign it. For instance, if the current version was 2.5, CVS would want to name the next version 2.6. Of course, if you think there are enough changes to warrant a completely new version designation, you can use the following to force it:
$ cvs commit -r3.0 filename |
$ cd ~/cvs $ emacs my_new_file.sgml $ cvs add my_new_file.sgml $ cvs commit |
Of course, you may substitute your favorite editor for emacs.
To get the changes that the other developers have added to the repository since you last checked, do
$ cd ~/cvs $ cvs update |
If a new directory has been added to the central repository since your last checkout you can do
$ cvs update -d |
The CVS book at http://cvsbook.red-bean.com/ has fairly comprehensive coverage.