Randal L. Schwartz wrote:
"Ramprasad" == Ramprasad A Padmanabhan <[EMAIL PROTECTED]> writes:
Ramprasad> $exp->expect(1);
This means "wait at most 1 second for *any* output".
Yes I thought for a simple command like date that should be OK
even If I put $exp->expect(1,/.*2005.*/s) I get no ou
> "Ramprasad" == Ramprasad A Padmanabhan <[EMAIL PROTECTED]> writes:
Ramprasad> $exp->expect(1);
This means "wait at most 1 second for *any* output".
Do you really want to do that? Perhaps you should be waiting for a
newline or something.
--
Randal L. Schwartz - Stonehenge Consulting Serv
I am using perl Expect to spawn a shell, run date and get its output ..
I am not getting the full output of date
Here is the script, can someone tell me where am I going wrong ?
#!/usr/bin/perl
use Expect;
my $exp = Expect->spawn('bash');
print $exp->send("date\r");
$exp->expect(1);
my $str =