read -p 和 echo 鍵盤讀入,屏幕輸出,5秒超時
[root@localhost ~]# cat read.sh
#!/bin/bash
read -t 5 -p "Please input a string:" string
echo $string
read -p 和 echo 鍵盤讀入,屏幕輸出,5秒超時
[root@localhost ~]# cat read.sh
#!/bin/bash
read -t 5 -p "Please input a string:" string
echo $string