linux-find
记录生活中的点点滴滴~
[akuma@centos test]$ ls akuma.txt akuma.Txt akuma.TXT [akuma@centos test]$ pwd /home/akuma/test [akuma@centos test]$ ls akuma.txt akuma.Txt akuma.TXT [akuma@centos test]$ find . -name "*.txt" ./akuma.txt [akuma@centos test]$ find . -iname "*.txt" ./akuma.Txt ./akuma.txt ./akuma.TXT [akuma@centos test]$
#当前所在目录 pwd # find命令 find . #列出当前目录及子目录下所有文件和文件夹 find /home -name "*.txt" #在/home目录下查找以.txt结尾的文件名 find /home -iname "*.txt" #在/home目录下查找以.txt结尾的文件名,但忽略大小写 find . -empty #列出所有长度为零的文件