摘要:
#!/usr/bin/bash while read line #读取一行结果 do if [ ${#line} -eq 0 ];then #如果有空行的话就跳过这次循环 contiune fi user=`echo $line|awk '{print $1}'` pass=`echo $line| 阅读全文
摘要:
#!/usr/bin/bash >ip.txt for i in {2..254} do { ip=192.168.234.$i ping -c1 -W1 $ip &>/dev/null if [ $? -eq 0 ];then echo "$ip" | tee -a ip.txt fi }& #这 阅读全文
摘要:
#!/usr/bin/bash read -p "Please input a username:" user id $user &>/dev/null if [ $? -ne 0 ];then echo "no such user: $user" exit 1 fi read -p "Are yo 阅读全文