Re: Issue Unix command in Perl and get back the result

2002-01-02 Thread John W. Krahn
Families Laws wrote: > > The Unix command is: `cp -ip $file1 $file2`. I needed > to know if the cp operation is successful. I tried > $result = `cp -ip $file1 $file2`; > $result does not contain any value after the execution > even when $file1 does not exist. > > How can I find out if the 'cp' o

Re: Issue Unix command in Perl and get back the result

2002-01-02 Thread Peter Scott
At 10:21 PM 1/2/02 -0800, Families Laws wrote: >The Unix command is: `cp -ip $file1 $file2`. I needed >to know if the cp operation is successful. I tried >$result = `cp -ip $file1 $file2`; >$result does not contain any value after the execution >even when $file1 does not exist. > >How can I find o

Issue Unix command in Perl and get back the result

2002-01-02 Thread Families Laws
The Unix command is: `cp -ip $file1 $file2`. I needed to know if the cp operation is successful. I tried $result = `cp -ip $file1 $file2`; $result does not contain any value after the execution even when $file1 does not exist. How can I find out if the 'cp' operation is successful or not ? Thank