Ivan Novick wrote:
>
> Hi,
Hello,
> does anyone know syntax to run a command and redirect its output directly to
> a file?
>
> Equivalent to myCommand > myFile in shell
open my $pipe, 'myCommand |' or die "Cannot open pipe from myCommand:
$!";
open my $fh, '>', 'myFile' or die "Cannot open myF
Marcos Rebelo wrote:
>
> What is your real problem?
>
Exactly. Using Perl as an agent to simply run a
program and record its output is misuse. Just
use a shell script.
What are you trying to do?
/R
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTEC
Sent: Tuesday, August 26, 2003 7:14 AM
To: Ivan Novick; [EMAIL PROTECTED]
Subject: RE: redirecting the output of a command to a file
system("myCommand > myFile");
must work
-Original Message-
From: Ivan Novick [ mailto:[EMAIL PROTECTED]
<mailto:[EMAIL PROTECTED]
Is there no other way some perl syntax to redirect to a file the output of a
command?
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: Tuesday, August 26, 2003 7:14 AM
To: Ivan Novick; [EMAIL PROTECTED]
Subject: RE: redirecting the output of a command to a file
system("myCommand > myFile");
must work
-Original Message-
From: Ivan Novick [mailto:[EMAIL PROTECTED]
Sent: Tuesday, August 26, 2003 1:11 PM
To: [EMAIL PROTECTED]
Subject: redirecting the output of a command to a file
Hi,
does anyone know syntax to run a command and redirect its output