Reputation: 27105
How can I match a blank line in expect? expect -r "" {send "y\n"}"
causes y
to be entered immediately.
|
| Type 'y' to accept:
|
<---- match this blank line!
Upvotes: 3
Views: 1668
Reputation: 27105
Etan Reisner's suggestion of matching consecutive newlines works.
expect -r "\r\n\r\n" {send "y\n"}
Upvotes: 1