Command-line search with Spotlight
Spotlight can be powerful and fast, but lacks some precise control over the results. Typically you get far more results than you would ever need. The command-line interface unlocks more advanced functionality and you can also integrate it into your scripts.
The core command is “mdfind” and you could do …