# 判斷hosts中有域名 if cat '/etc/hosts' | grep "$input_domain" then echo "域名爲$input_domain已存在" domain_flag='' continue fi