Subj : ANNOUNCE: cvs-repository.pl -- change contents of CVS/* files To : All From : Jari Aalto+mail.emacs Date : Thu Mar 01 2001 03:13 pm From: jari.aalto@poboxes.com (Jari Aalto+mail.emacs) All of you that need to chnage repository locations from time to time, here is script that has been uploaded to CPAN. http://www.cpan.org/modules/by-authors/id/J/JA/JARIAALTO/ NAME @(#) cvs-repository.pl - Change CVS repository file contents README CVS is a concurrent version control system and available for multiple platforms at `http://www.cvshome.com'. This program will help changing the content of client files Root, Repository, Entries and Tag. From time to time there is a need to change the repository locations and this needs immediate changin in following files: Before: CVS/Root /cygdrive/g/data/version-control/cvsroot CVS/Repository emacs/gnu-emacs/lisp After: CVS/Root /cygdrive/h/data/version-control/cvsroot CVS/Repository emacs/gnu-emacs/lisp In the above example, the Win32 http://www.cygwin.com/ hard disk repository was changed from disk g (that possibly filled up) to a partition h. Any similar change can be carried out with any of these files. The changes to the files are made using perl code that is evaled and for the above situation the command line parameters in Win32 would be: perl -S cvs-repository.pl --name "/Root$" --eval "s,/g/,/h/," . SYNOPSIS cvs-repository.pl --name FILE-REGEXP --eval PERL-CODE DIR [DIR DIR ..] OPTIONS Gneneral options --name FILE-REGEXP Search files that match regexp for modification. The regexp is amtched against absolute path name, so don't use "^Repository$" to match file exactly, but the leasing forward slash for absolute name: "/Repository$" --eval PERL-CODE Evaluate perl code for each line in the found file. The current line is available at $ARG, so simple substrirutions s/search/substitute/ are the most used ones. However, you can include any valid perl e.g in "do{ the; code; here }". --- BBBS/LiI v4.01 Flag-2 * Origin: Prism bbs (1:2320/38) .