摘要: 方法一:利用grep查找 strA="long string" strB="string" result=$(echo $strA | grep "${strB}") if [[ "$result" != "" ]] then echo "包含" else echo "不包含" fi 先打印长字符串 阅读全文
posted @ 2022-04-20 11:00 业余砖家 阅读(1060) 评论(0) 推荐(0)