使用正規表示是來比對整個字串。 系統內定變數$? 的結果. 0是成功。 1是失敗。 $ echo abcd | grep '^abcd$' >> /dev/null; echo $? 0. 【參考】. shell script 裡如何 ...
確定! 回上一頁