How do I search for a specific jar file within a while loop? In the code below, $application
, $location
, $version
are command line arguments
sub do_verify
{
while($application eq 'abc')
{
my $dir = "/viewstore/ccabc/dst_${application}_${version}/abcportal/${location}/target";
opendir(DIR, $dir) or die $!;
my $jarfile;
next unless ($jarfile =~ /\.jar$/);
print "$jarfile\n";
do_upload();
}
}