- 元字符
- 扩展元字符
- 文件的查找命令 find
- 文本内容的过滤(查找)grep
grep password /root/anaconda-ks.cfg- ? 元字符 正则表达式
grep pass.... /root/anaconda-ks.cfg
- ? 元字符 正则表达式
- 字符串 Do one thing at a time,and do well.
- 匹配字符 an
[Hh]ello
grep ^#
\ 转义符
grep "."
- 匹配前面的正则表达式至少出现一次
?
find *txt
cut -d ":" -f7 /etc/passwd | sort | uniq -c |sort -r
find 目录中找到指定的文件
cd /etc
find passwd
ls passwd*
find passwd.*
find /etc -name passwd
find /etc -name pass*
find -regex
man find
find /etc -regex .*wd
find /etc -regex .etc.*wd
find /etc -type f -regex .*wd