in reply to Re: Passing the contents of a file in a "system" call to a .ksh script
in thread Passing the contents of a file in a "system" call to a .ksh script
open my $FH, "<$LOGFILE" or die "Failed to open $LOGFILE"; while ($LINE = <$FH>) { push @contents, $LINE; } close $FH; print LOG "$FORMATTEDTIME @contents \n"; my @args = ("/home/admin/bin/email.ksh", "@contents", "Web Server +Issue", "PROD", "/home/admin/logs/check_jvm/EmailAlert.log"); system(@args) == 0 or die "system @args failed: $?"
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Passing the contents of a file in a "system" call to a .ksh script
by kennethk (Abbot) on Jan 08, 2009 at 20:31 UTC | |
by BrotherElwood (Initiate) on Jan 08, 2009 at 20:51 UTC | |
by kennethk (Abbot) on Jan 08, 2009 at 21:13 UTC | |
by BrotherElwood (Initiate) on Jan 08, 2009 at 21:31 UTC |