This page describes how to to set up WinCVS to connect to a remote CVS server via SSH.

Note:

Please note that I have tried to make all instruction below as close as possible to the typical setting of a machine in UDBL, but there might be a need to change drive, folder names, etc. according to your configuration.

Usage Scenario

The following scenario is addressed: you are a developer running Windows (95/98/NT). You'd like to be able to access from anywhere a CVS repository which is located on a UNIX server.

Our solution at UDBL is:

Run a CVS client on your Windows box, which uses an SSH client to connect and exchange data with a remote UNIX server where the CVS server runs.

The following describes how to set your environment, so that you can use a Windows GUI CVS front-end called WinCVS to connect to a remote CVS repository. There are two steps involved:

  1. Set up your Windows to run SSH appropriately
  2. Configure your WinCVS

Setting up command-line SSH for Windows for use with WinCVS


download command-line ssh
Prerequisite:
your Windows user name must be the same as your unix user name. If it differs, I don't know how to make WinCVS pass parameters to the command line CVS (in this case the "-l username" parameter)
  1. Before runinig any of the SSH programs, set permamently your HOME variable to something.
    Example: HOME=e:\
    SSH will create there a directory .ssh e.g.: e:\.ssh
    Set your path to contain the location of SSH.EXE
    Example: PATH=d:\programs\ssh
    Note: to set an environment variable on Windows NT right click on "My Computer", and select "Properties", tab "Environment".

Setting up WinCVS


A. download WinCvs 1.2
B. Install it
C. Start it
D. Press Ctrl+F1 (or menu: "Cvs Admin/Preferences") and make the following changes to the default settings:

  1. Select tab "General"
    Enter into the filed CVSROOT the following information:
    <username>@<server_hostname>:<cvs_full_root_path_on_the_server>
    Example: timka@ida.it.uu.se:/dis/projects/udbl/CVSRoot
    Enter into the field Authentication: "SSH server"
  2. Select tab "Globals"
    Uncheck: "Check-out read only"
    Uncheck: "Use TCP/IP compression", if it is checked (it is needed only over slow lines).
    Uncheck: "Dirty files ..."

E. To get your first copy of the repository, select menu: "Cvs Admin", submenu: "Check-out module". You will be asked for a location of the new module. When you check-out a new module a new directory with it's name will be created.
Example: if you select the directory "E:\work", then after check-out of the module AmosNT, you will have the directory: "E:\work\AmosNT"

F. If you want to use CVS from the command line prompt, this is a copy of an example BAT file, that sets the necessary environment variables, and runs CVS (you have to replace "timka" with your user name):
@echo off
set SAVE_CVSROOT=%CVSROOT%
set CVSROOT=:ext:timka@ida.it.uu.se:/dis/projects/udbl/CVSRoot
set CVS_RSH=ssh
set CVS_SERVER=/dis/projects/udbl/bin/cvs
"d:\programs\WinCvs\cvs" %1 %2 %3 %4 %5 %6 %7 %8 %9
set CVSROOT=%SAVE_CVSROOT%


You might also set these variables permanently in your Windows environment.

Removing prompt for password


See How to set up public key on remote server so you don't have to type password when logging in.

Written by Timour Katchaounov. Last modified: Tue Mar 30 16:29:56 W. Europe Daylight Time 2004 .