#!/usr/bin/expect -f
spawn scp -r -P 端口号 [email protected]:/file/ /file(从远程复制下来,上传的话只要位置颠倒一下就可以了)
set timeout 100
expect "password:"
send "123344\n";
interact
#!/usr/bin/expect -f
spawn scp -r -P 端口号 [email protected]:/file/ /file(从远程复制下来,上传的话只要位置颠倒一下就可以了)
set timeout 100
expect "password:"
send "123344\n";
interact