Subject: Re: switching CVS repository from pserver to ssh without reimporting
To: None <wleeson@indigo.ie>
From: Martti Kuparinen <martti.kuparinen@iki.fi>
List: netbsd-help
Date: 01/15/2003 21:24:23
wleeson@indigo.ie wrote:
> Hi All,
> 	I have the sources for XFree (the NetBSD ones) but I checked them out using pserver instead of ssh. So I was wondering is it possible to switch the source to ssh without reimporting the entire source tree (Yeah I only have a 56k modem sigh).
> 
> Regards,
> 	William Leeson 
> 

I'm quite often using the following script to modify my CVS/Root files.

# move-cvsroot /usr/xsrc anoncvs@anoncvs.netbsd.org:/cvsroot
#
# cd /usr/xsrc
# export CVS_RSH=ssh
# cvs update -dPA

Martti


#!/bin/sh

if [ $# -ne 2 ]; then
     echo ""
     echo "Usage:   `basename $0` base-directory new-root"
     echo "Example: `basename $0` /home/proj/something /cvsroot"
     echo ""
     exit 1
fi

for i in `find "${1}" -name CVS`
do
     [ ! -r "${i}/Root" ] && continue

     echo "${i}"
     echo "${2}" > "${i}/Root" || exit 1
done