开发者

find command + to search direcories

开发者 https://www.devze.com 2023-01-06 00:30 出处:网络
I used the following find command to search files find /tmp -regex \".*some_file\" How I can to search on the same way directories开发者_如何学Python?

I used the following find command to search files

   find /tmp -regex ".*some_file" 

How I can to search on the same way directories开发者_如何学Python?

Yael


Add the -type d test:

find /tmp -type d -regex ".*some_dir"


find /tmp -regex ".*some_dir" -type d


If I understood your question correctly:

find /tmp -regex "some_dir" -type d
0

精彩评论

暂无评论...
验证码 换一张
取 消