![]() |
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Calling expect scripts from other expect scripts | seva | Shell Programming and Scripting | 0 | 04-03-2008 02:45 PM |
| tcl/expect | calsum | Shell Programming and Scripting | 7 | 03-26-2008 01:23 AM |
| Expect/Tcl help? | earnstaf | UNIX for Dummies Questions & Answers | 2 | 07-26-2007 11:01 AM |
| want to use output of c programme in expect | xander | Shell Programming and Scripting | 0 | 06-13-2007 01:36 PM |
| Expect and auto expect command | arun_v | Shell Programming and Scripting | 0 | 03-29-2006 08:31 AM |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
||||
|
Get the output from EXPECT ?
I'm using expect script, but don't know how to assign an output to a string variable. Any help ?
Thank you for reading! PS: In fact i want to get the out put of expect when run grub-md5-crypt to generate MD5 password for GRUB boot loader. My code: Code:
#!/bin/sh
#\
exec expect -f "$0" ${1+"$@"}
set password 123456
set timeout 5
spawn grub-md5-crypt
expect "asspword:"
send "$password\r"
expect "passpword:"
send "$password\r"
expect eof
Any ideas? Last edited by fongthai; 11-23-2006 at 05:26 AM.. |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|