Get the App
SLTechnology News&Howtos  ›  Development  › 

How to implement nested execution of expect commands in shell

Shulou Source: shulou.com Published: 2022-06-03 09:19:19 11月15日 Update

This article mainly explains "how to implement the expect command nested in the shell", interested friends may wish to take a look. The method introduced in this paper is simple, fast and practical. Let's let Xiaobian take you to learn "how to implement the expect command nested in the shell"!

1. Install expect first

The code is as follows:

yum -y install expect

2. Script content:

The code is as follows:

cat auto_svn.sh

#!/ bin/bash

passwd='123456'

/usr/bin/expect

Tags: Commands content code learning practical deeper interested practical practical easy to operate methods more friends websites scripts channels queries Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Linux MySQL Xiaomi Shulou Information Shulou Technology