Expect

Expect is a Tcl based language that is often used to automate command line applications.


 * 1) !/usr/local/bin/expect -f


 * 1) Example exec program that logs into an anonymous ftp server

set timeout 10 ;# 10 seconds is default

spawn /usr/bin/ftp $argv expect "Name" send "anonymous\n" expect "Password:" send "blah@example.com\n" interact