My perl scripts would need to examine a log file. I would like to raise an error to user when
1) On any of the lines, the word Error or Warn occurs on its own (i.e. would not count
or
How could I do that? My best guess is
But it does something else instead
1) On any of the lines, the word Error or Warn occurs on its own (i.e. would not count
Code:
Without errors
Code:
Without warnings
How could I do that? My best guess is
Code:
$outputStr =~ /Error/i or $outputStr =~ /Warn/i) and
!($outputStr =~ /without Error/i and
$outputStr =~ /without Warng/i))
But it does something else instead