shell判断字符串包含 strA="helloworld" strB="low" if [[ $strA =~ $strB ]] then echo "包含" else echo "不包含" fi 摘自