2 # wait for a string to appear at the end of file
3 # tridge@samba.org July 2008
7 Usage: waitfor FILE MESSAGE TIMEOUT
19 spawn tail -n 10000 -f $file
20 expect -timeout $timeout -re "$msg"
27 if ! grep -E "$msg" $file > /dev/null; then
28 echo "Failed to find \"$msg\" in $file"