[Linux]文件及目录搜索

find . -name "*temp*": 搜索当前目录及子目录下所有包含"temp"的文件和目录

find . -name "*.txt" -exec grep -l "a"  {} \;  : 搜索当前目录及子目录下所有包含"a"的txt文件 (注意{} 和 \之间要有空格)

Leave a Comment

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.