Personal tools
You are here: Home Members taus007's Home Perl Script to Change All of Your CVS Roots
Navigation
Log in


Forgot your password?
New user?
 

Perl Script to Change All of Your CVS Roots

Run with 'find ./ -name 'Root' perl -exec updateCVS.pl {} \;

Click here to get the file

Size 1 kB - File type text/plain

File contents

#!/usr/bin/perl -w

my $file = shift;
my $content = "";
open (FILE, $file) || die "Can't open $file: $!\n";
while (<FILE>)
  {
    s/\/product\/cmiss\/cvs/taus007\@cvs\.bioeng\.auckland\.ac\.nz\:\/cvs\/cmiss/g;
      $content .= "$_";
        }
        close(FILE);
        open (FILE, ">$file") || die "Can't open $file: $!\n";
        print FILE $content;
        close(FILE);