Mailing List Archive

Support open source code!


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: REGEXP in perl questiion



Thanks! Your second option worked, but the first one did not.

From your first email I tried:

if ( $_ =~ /^Subject: /) {
  if ($_ =~ "Cron") {
    #Extract the name of the prog that cron lauched
    $PROGNAME =~ s/.*\/([^\s]+)\s.*/$1/;
    $PROGNAME = $1; #doesn't matter if this line is here or not
    print "The program called by cron was $PROGNAME\n";
    #If this cron job is expected remove it from the list
  }
}

But it just printed out blanks.
_________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.


Home | Main Index | Thread Index

Home Page Mailing List Linux and Japan TLUG Members Links