IP ([0-9]+(/.[0-9]+){3})
^cat$ 完全匹配
^$ 空行
[] 匹配列表
[^] 不在列表
. 匹配任意字符 如果要匹配點 /.
egrep 開始操作前strip end-of-line character(s)
/< equal to ^
/> equal to $
? 可選項 如 4(th)? ====> (4th|4)
{n} 重複n次 {n,m} 重複n到m次 最多m
/t tab
/n 換行
/r 回車
/s whitespace (space, tab, newline, formfeed,)
/S not /s
/w [a-zA-Z0-9_]
/W not /w
/d [0-9]
/D not /d
perl -p -i -e 's/sysread/read/g' file
ignorecase regexp
egrep ==> grep -E
locate -r regexp