mirror of
https://gitee.com/cv_team/uestc-careye.git
synced 2024-11-30 10:48:37 +08:00
15 lines
502 B
Plaintext
15 lines
502 B
Plaintext
|
#!/usr/bin/expect
|
||
|
set timeout 30
|
||
|
set robot_remote_address "192.168.1.108" #此处填写目标树莓派的IP地址
|
||
|
set robot_remote_user "root"
|
||
|
set robot_remote_password "root\n"
|
||
|
set robot_remote_file_path "/root/workspace/uestc-careye"
|
||
|
set robot_remote_ssh $robot_remote_user@$robot_remote_address:$robot_remote_file_path
|
||
|
set robot_local_file_path "src"
|
||
|
|
||
|
spawn echo Push to $robot_remote_ssh
|
||
|
spawn scp -r $robot_local_file_path $robot_remote_ssh
|
||
|
expect "password:"
|
||
|
send $robot_remote_password
|
||
|
interact
|