lilalo
annotate lm-ssh @ 71:d499fa3b2af1
Na lilalo@moskau.xt.vpn uspeshno zavelos i\
zarabotalo. + Sohranenie istorii pri vyhode
zarabotalo. + Sohranenie istorii pri vyhode
author | devi |
---|---|
date | Sat Feb 04 00:47:22 2006 +0200 (2006-02-04) |
parents | |
children |
rev | line source |
---|---|
devi@0 | 1 #!/bin/sh |
devi@0 | 2 #\ |
devi@0 | 3 exec expect -- "$0" ${1+"$@"} |
devi@0 | 4 eval spawn ssh $argv |
devi@0 | 5 set timeout 1 |
devi@0 | 6 expect { |
devi@0 | 7 eof { |
devi@0 | 8 } |
devi@0 | 9 "(yes/no)? " { |
devi@0 | 10 send "yes\n" |
devi@0 | 11 exp_continue |
devi@0 | 12 } |
devi@0 | 13 assword: { |
devi@0 | 14 send "rootpass\n" |
devi@0 | 15 } |
devi@0 | 16 timeout { |
devi@0 | 17 interact -nobuffer |
devi@0 | 18 } |
devi@0 | 19 } |
devi@0 | 20 expect { |
devi@0 | 21 eof { |
devi@0 | 22 } |
devi@0 | 23 assword: { |
devi@0 | 24 send "rootpass\n" |
devi@0 | 25 } |
devi@0 | 26 |
devi@0 | 27 timeout { |
devi@0 | 28 interact -nobuffer |
devi@0 | 29 } |
devi@0 | 30 } |
devi@0 | 31 |