Packages: LIBDB CVS

Use: Debug

What is CVS?

CVS is a acronym of Concurrent Version System. It's a complete free Version System and it's very used in TinyCOBOL project.

With it, developers and users get the code of TinyCOBOL and made your own compilations.

Developers can access the CVS with write access and make changes in the compiler code.

Users can access the CVS with anonymous user and get the code.

A great book about CVS are stored in cvsbook home.

What CVS repository should I get?

The TinyCOBOL project does have some CVS repositories, used as follows:

You can select one repository by it name or select all repositories using a period (.).


cvs checkout development	(You will get the development repository).


cvs checkout development samples (You will get the development and samples


cvs checkout .	(You will get all repositories)		

First Steps

Creating the .cvspass file

CVS require a file called .cvspass, to check if the user are logged in or not in the CVS repository. In the first time that you access the CVS server, you will need of create a blank .cvspass file.

To create this file just type this:

echo " " > .cvspass

The .cvspass must be added in the $HOME directory, where $HOME is a environment variable.

In Win32 environments, don't use the copy con program to create the .cvspass file because the CVS don't make the authentication of the .cvspass file. Use the edit editor or the echo command to create the .cvspass file.

Making the process more easy.

  1. If you are a user, to make easy the CVS process, you can create a simple file with this commands, depending from the operating system:

    POSIX environment: (Remember to add binary permissions to this file)

    echo "#!/bin/sh" > cvs-setup.sh
    echo "export CVSROOT=:pserver:anonymous@cvs.sf.net:/cvsroot/tiny-cobol" >> cvs-setup.sh

    DOS environment:

    echo "@echo off" > cvs-setup.bat
    echo "set HOME=." >> cvs-setup.bat
    echo "set CVSROOT=:pserver:anonymous@sf.net:/cvsroot/tiny-cobol" >> cvs-setup.bat

  2. If you are a developer, the process are the same, however you will need to make some additional changes in the scripts:

    POSIX environment:(Remember to add binary permissions to this file)

    echo "#!/bin/sh" > cvs-setup.sh
    echo "export CVS_RSH=ssh" >> cvs-setup.sh
    echo "export CVSROOT=:ext:yoursfusername@cvs.sf.net:/cvsroot/tiny-cobol" >> cvs-setup.sh

    DOS environment:

    echo "@echo off" > cvs-setup.bat
    echo "set HOME=." >> cvs-setup.bat
    echo "set CVS_RSH=ssh" >> cvs-setup.bat
    echo "set CVSROOT=:ext:yoursfusername@sf.net:/cvsroot/tiny-cobol" >> cvs-setup.bat

Starting the CVS script file

Every time that you need to get the TC code from CVS, start the batch or script file before.

POSIX environment:

sh cvs-setup.sh

DOS environment


How could I get the code in anonymous mode

  1. After of start the CVS script file Log in like a anonymous user invoking the login command:

    cvs login

  2. CVS will you ask to you the password, however don't exist a password for the anonymous user. So, press ENTER

  3. Now, you are able to get the TC source code, so, invoke the checkout(co) command:

    cvs checkout [repositoryname]

    cvs co [repositoryname]

  4. After of the checkout command be invoked, you should log out from the CVS server using the logout command:

    cvs logout 

  5. To see the code, go to the repositoryname directory, where repositoryname is the name of the CVS repository.

How could I get the code in developer mode?

Do exist some important differences between get the code in anonymous mode and get the code in developer mode.

This diferences are:

So, in the developer mode you won't need of use the commands login and logout because every command in developer mode will login in CVS server, check the user permissions, make the command required by the user and after logout from the CVS server.

  1. After you start the CVS script file, you can invoke the checkout(co) command:

    cvs checkout [repositoryname] 
  1. The CVS will ask you your password. Type your SF user password and press ENTER.

Using the cvs2cl tool

The cvs2cl tool is a acronym of CVS to ChangeLog and it's just a perl script that get a CVS log file. It's very useful to know more informations about the last changes added by the developers of the project.

You can get it from Karl Fogel's web site

  1. To use it, just type "cvs2cl -r" in the repository that you want to generate a log about the last changes.

    $ cd [repositoryname]
    $ cvs2cl -r 

  2. The CVS server will ask you your SF password. You can press ENTER if you are a anonymous user or type your SF password, just in case of you be a developer.

  3. After the cvs2cl process, see the ChangeLog file.