if else
if
if 語句語法格式:bash
if condition then command1 command2 ... commandN fi
if [ $(ps -ef | grep -c "ssh") -gt 1 ]; then echo "true"; fi
末尾的fi就是if倒過來拼寫,後面還會遇到相似的。ssh
if 語句語法格式:bash
if condition then command1 command2 ... commandN fi
if [ $(ps -ef | grep -c "ssh") -gt 1 ]; then echo "true"; fi
末尾的fi就是if倒過來拼寫,後面還會遇到相似的。ssh