Hi All,

I have perl script like this :

use strict;
use warnings;
use Cwd;
my $chver;
my $fina;
&chversion();

sub chversion {
  print STDERR "Current directory is " . cwd() . "\n";
  print "Reading version file\n";
open (VER2, "<", 
'D:\hudson\workspace\RTU_Trunk_Build_Official\Trunk\versions.txt') or die 
"Couldn't open versions.txt for reading: $!\n";
while (<VER2>) {
  $chver=$_;
}
 print "$chver\n";
open (VER1, "+>", 
'D:\hudson\workspace\RTU_Trunk_Build_Official\Trunk\Metrino\MonitoringSystem\Rtu\RtuInstallKit\EXFO
 RTU System\EXFO RTU System') or die "Couldn't open versions.txt for 
read/write: $!\n";
print "Hi\n";
while (<VER1>) {
 print "HI\n";
   if ($_ =~ m/"OutputFilename"/) {
    print "Match found\n";
       $fina =~ s/$_/{.*}$chver.msi/;
   }
 
}
 print "$fina\n";
 close VER1;
 }

the issue is that , it is executing properly till while loop but it is not 
going inside the while and executing while loop.
there is no any error and all the files are present in their location.

please plase help

Regards
Irf


      

Reply via email to