Section A.1. Multi-Operating-System Clients


A.1. Multi-Operating-System Clients

If your development team is not familiar with CVS, you may want to ensure that everyone is using the same CVS client. This step helps minimize support problems; if someone has a problem, his fellow developers are familiar with the tools he's using and can offer helpful advice.

The clients described in this section look and operate the same across several different environments. The first three represent a set of clients that are designed for all three major operating systemsUnix/Linux, Macintosh, and Windowsand work from the same base code. The other GUI clients are Java clients that work on any operating system with a Java Runtime Environment, and a client called Concurrent Versions Librarian.

A.1.1. gCVS, WinCVS, and MacCVS

Three GUI clientsgCVS, MacCVS, and WinCVSrepresent a set of clients available from the same development team that work identically across Unix/Linux, Macintosh, and Windows operating systems. The clients are detailed and implement most of the functions available from the CVS command line. Using these clients, you can create a new repository, tag files, create watches, and report on the differences between files. These clients are available from http://www.wincvs.org and http://cvsgui.sourceforge.net.

gCVS is for Linux and Unix (including Mac OS X), WinCVS is for Windows, and MacCVS is for Macintosh (both pre-OS X and post-OS X versions exist). Because their interfaces are so similar, these clients are good for groups that develop software across different operating systems.

These clients are laid out with three main windows, as shown in Figure A-1 (gCVS) and Figure A-2 (WinCVS). The leftmost window contains a directory tree, the base directory of which is configurable. The upper-right window shows the contents of the current directory, and the lower-right window shows the output of the CVS commands that you execute using the GUI.

Figure A-1. The gCVS main window


Figure A-2. The WinCVS main window


Using these GUI clients, you execute CVS commands by choosing a menu option and then filling out some fields in a dialog. The output of most commands is displayed in the lower-right window. This display can be irritating if the output from a given command is particularly large or complex to read. Fortunately, you can resize the output window to accommodate large and complex output. If you need to use options that are not available in the menus and dialogs, you can run command-line commands in these clients using the Command Line option in the Admin menu.

Figure A-3 shows a sandbox open in MacCVS.

Figure A-3. MacCVS


In Chapter 2, I recommended gCVS, WinCVS, and MacCVS as CVS clients for a development team because they are popular and have a common interface. Installation is similar for all CVS clients on the same operating system, so I've chosen these three to give an example for each operating system.

A.1.1.1. Installing gCVS

gCVS is a Linux and Unix client available from http://www.wincvs.org and http://cvsgui.sourceforge.net. You can install it from source, or you can use a package manager. To use a package manager, follow the procedures given in the section "Installing CVS" in Chapter 2.

To install CVS from source, read the detailed instructions in the section "Installing CVS" in Chapter 2. The procedure for installing gCVS is similar to the procedure for installing CVS, though some of the commands differ slightly:

  1. Decompress and expand the .tar.gz file using tar -zxf filename.

  2. Read the INSTALL file in the top directory of the source tree. If the instructions in the INSTALL file differ from the instructions here, use the instructions in the INSTALL file.

  3. Check whether the gtk development libraries are available. gCVS needs to link to these libraries when it compiles. They are available from http://www.gtk.org.

  4. Change directories into the top directory of the source tree.

  5. Run ./make-configure --prefix=directory, where directory is the location into which you want to install gCVS.

  6. Run make.

  7. Change user to root, then run make install.

  8. Add the installation directory to the path for your gCVS users.

  9. Run gCVS with the gcvs command.

Whether you install gCVS as a package or from source, you may also need to install or configure SSH or Kerberos. If you intend to use SSH and have not used it before, you need to generate keys. If you are currently using SSH, you should already have keys. As an SSH client is often installed by default in Unix and Linux systems, you may only need to configure it.

A.1.1.2. Installing WinCVS

WinCVS requires Python. If you intend to connect with SSH, it requires you to install SSH as well. These instructions assume that you will run WinCVS with SSH. Older versions of WinCVS used Cygwin instead of Python.

  1. Install Python 2.1 or later from http://www.python.org.

  2. Install an SSH client such as Putty. Putty is available at http://www.chiark.greenend.org.uk/~sgtatham/putty/. Ensure that you get the plink program as well as the basic Putty.

  3. Use the key-generation program for your SSH client. Store both private and public keys in files. If the key generator gives you a public key to cut and paste, use Notepad or another text editor to store the key in a file. Generate an ssh1 or ssh2 key, depending on your server's SSH protocol.

  4. Put a copy of the public key on the server, in your ~/.ssh/authorizedkeys file or whichever file your server's SSH program expects public keys to be in.

  5. If your SSH client runs a key agent, use it. Putty runs Pageant, which has an icon in the system tray. Add your private key to the key agent; to do this in Pageant, right-click on the icon and select View Keys, then Add Key.

  6. Download WinCVS from http://www.wincvs.org.

  7. Extract WinCVS using the extractor provided; it's distributed in a self-extracting archive.

  8. Run setup.exe.

  9. Run WinCVS.

  10. Set ssh as the connection method. Use the following procedure:

    1. Select Preferences from the Admin menu.

    2. Open the General tab. Set the authentication option to ssh.

    3. Open the Settings button, and then fill in the path to your SSH client. For Putty, the executable is plink.exe. Also set any options necessary for your SSH client. If you are using Putty, set the -ssh option.

A.1.1.3. Installing MacCVS

MacCVS is distributed as a compressed image and needs to be opened with StuffIt, which is available for both OS X and pre-OS X systems. Most Macintosh systems have StuffIt installed; if yours doesn't, you can get StuffIt Expander (the free version) from http://www.stuffit.com/mac/index.html. Once you've downloaded the compressed archive, just double-click it to open and install the program. That's it! You're done with the installation. To run MacCVS, open the MacCVS icon from the directory in which you installed it.

MacCVS and clients written for Macintosh systems older than OS X do not support SSH through the usual access method, where the repository path is :ext:hostname:/path and the CVS_RSH environment variable is used. To work around this limitation, install an SSH client that supports port tunneling and use an SSH tunnel to connect to the CVS repository securely. Choose an alternate access method such as pserver or kserver and configure MacCVS to connect to the localhost on the port at the local end of the tunnel.

If you have OS X and want SSH support, try using the OS X-specific client, or use a Unix or Linux client.

A.1.2. CVL

CVL (Concurrent Versions Librarian) is an open source GUI frontend to CVS, available for Mac OS X and systems in the OPENSTEP family. It supports many commonly used CVS commands and multiple repositories, and it integrates with FileMerge (shipped with Mac OS X Developer Tools) to resolve merges and conflicts.

The Concurrent Versions Librarian is available from http://sente.epfl.ch/software/cvl/. Figure A-4 shows a CVL sandbox.

Figure A-4. Concurrent Versions Librarian


A.1.3. CrossVC

CrossVC, formerly LinCVS, is available from http://www.lincvs.org. It supports Linux/Unix, Mac OS X, and Windows environments. On Linux/Unix, it requires the QT toolkit, but it runs in most graphic environments.

Start using CrossVC by selecting the "Add to workbench" option under the Projects menu and choosing a top-level directory above at least one of your sandboxes. CrossVC searches the directory and determines which files are controlled by CVS. It then adds those files to the workbench, which is a directory tree in the left window. The workbench is updated automatically on a periodic basis with a configurable timeout. You can add multiple directories to your workbench.

A.1.4. jCVS

jCVS is a Java-based CVS client (available from http://www.jcvs.org) that is useful for development teams who need to work over a variety of operating systems. The tabs in the main window (shown in Figure A-5) control project administration, and the menus in the project window control the commands for the files.

Figure A-5. The jCVS main window


The project window displays the files' hierarchy and the status of each file currently in the sandbox. Output from log, diff, and other commands is shown in a separate window.

A.1.5. SmartCVS

SmartCVS is a Java-based client that runs on any operating system with a Java Runtime Environment. SmartCVS is available from http://www.syntevo.com.

There are two versions of SmartCVS: a free version and a professional version. Both implement the basic CVS commands and connections with both pserver and SSH. The professional version supports the watch suite of commands, and has extended conflict resolution and file comparison tools.

The main window has three parts: the folder hierarchy to the left, the files in the current sandbox in the right window, and CVS command output in the bottom window. SmartCVS provides side-by-side, color-coded displays of the differences between revisions, and a log display that includes graphical representation of branches.

Figure A-6 shows the SmartCVS main window in the background and the graphical log display in the foreground. The log display shows a branched file.

Figure A-6. SmartCVS log display and main window





Essential CVS
Essential CVS (Essentials)
ISBN: 0596527039
EAN: 2147483647
Year: 2006
Pages: 148

Similar book on Amazon

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net