find command won't list keynote files

Joined
Feb 3, 2008
Messages
304
Reaction score
5
Points
18
I entered the find command in Terminal to look for all the keynote presentations that started with the number 2011:
Code:
find . -iname "2011*.key" -type f


but I got no results. The files are in there -- I can see them in the finder window. Can anyone tell me why it won't do this? If I just enter the command without '-type f' then it lists the files. Are keynote presentations not files or something?

I'm in the correct directory as well
 

vansmith

Senior Member
Joined
Oct 19, 2008
Messages
19,924
Reaction score
559
Points
113
Location
Queensland
Your Mac's Specs
Mini (2014, 2018, 2020), MBA (2020), iPad Pro (2018), iPhone 13 Pro Max, Watch (S6)
Probably because you're specifying the type. As I recall, iWork documents are actually bundles. In other words, they're glorified folders. Since they're technically folders and you're specifying the type "regular file", it's possible it's skipping over them. Try using type d. Actually, you can probably get away with excluding type altogether.
 

Shop Amazon


Shop for your Apple, Mac, iPhone and other computer products on Amazon.
We are a participant in the Amazon Services LLC Associates Program, an affiliate program designed to provide a means for us to earn fees by linking to Amazon and affiliated sites.
Top