-#!/usr/bin/expect -f -d
+#!/usr/bin/expect -f
+
+#enables some diagnostic output
+exp_internal 1
# log all interaction to a file to diagnose failures
log_file -a [lindex $argv 0]
send "m\r"
exp_continue
}
+ -re "\n *(\[^\n]* \\\[Y\/n\/m\/\\?] \\(NEW\\)) " {
+ puts "$expect_out(1,string) m"
+ send "m\r"
+ exp_continue
+ }
+ -re "\n *(\[^\n]* \\\[Y\/\\?] \\(NEW\\)) " {
+ puts "$expect_out(1,string) y"
+ send "y\r"
+ exp_continue
+ }
}