Spotlight Query Exclude Specific Folder(s)

2

2

I want to exclude specific folders from a spotlight query. I do NOT want to exclude them from indexing in general -- I just want to exclude them from my current query. I know how to add exclusion clauses to my queries (hold down alt/option and then click the ellipses and then click 'none'), however I don't know the field I'm supposed to choose. Is it 'Location,' 'URL,' 'Name'? I even tried using the mdls command on an example file in the folder I'm trying to exclude but I still don't know the name of the field that holds the file's path.

Jason Marcell

Posted 2011-04-16T21:01:39.510

Reputation: 1 153

Answers

0

You can use URL and e.g. file:///Users/danielbeck/* to exclude all items in my home directory, using * as wildcard operator.

Based on the description, I think Location refers to physical location e.g. in Photo metadata.

Name is just the file name itself, not the path.

Daniel Beck

Posted 2011-04-16T21:01:39.510

Reputation: 98 421