mdfind

OK so I can do this:

do shell script "mdfind kMDItemColorSpace == Gray -onlyin " & quoted form of POSIX path of This_Folder

But how do I construct the shell string so that I can match 2 items in the metadata? i.e. “kMDItemBitsPerSample == 3” as well do I pipe the commands or is there a way to pass a list?

Hello,

try something like…

set myVar to (do shell script "mdfind -onlyin /Users/MyUser/folder/files/ 'kMDItemKind == \"Adobe Photoshop file\" && (kMDItemPixelWidth >= 800 || kMDItemPixelHeight >= 600) ")

&& : logical And
|| : logical Or

Thank you, (just what I wanted && should have known.)