#!/usr/bin/perl use strict; use warnings; my $installLogFile = $ARGV[0]; my $destinationlocation = $ARGV[1]; sleep 1 until -f $installLogFile; chdir($destinationlocation) || die $!; print "Changing directory to $destinationlocation\n"; chdir('logs') || die $!; my $lastLine = `tail /1 $installLogFile`; chomp($lastLine); my $secondLastLine = `tail /2 $installLogFile`; chomp($secondLastLine); $secondLastLine =~ s/$lastLine//; chomp($secondLastLine); if($secondLastLine eq 'SUCCESSFUL') { print "successful\n"; } else { print " was not successful \n"; exit; }
In reply to Re: help need to read a listening log file
by markuhs
in thread help need to read a listening log file
by jithu_indian
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |