2015-10-26 12:55:32 +01:00
|
|
|
# mdfind
|
|
|
|
|
2016-01-07 18:31:27 +01:00
|
|
|
> List files matching a given query.
|
2015-10-26 12:55:32 +01:00
|
|
|
|
2016-01-07 18:31:27 +01:00
|
|
|
- Find a file by its name:
|
2015-10-26 12:55:32 +01:00
|
|
|
|
2015-12-07 00:01:50 +01:00
|
|
|
`mdfind -name {{file}}`
|
2015-10-26 12:55:32 +01:00
|
|
|
|
2016-01-07 18:31:27 +01:00
|
|
|
- Find a file by its content:
|
2015-10-26 12:55:32 +01:00
|
|
|
|
2015-12-07 00:01:50 +01:00
|
|
|
`mdfind {{query}}`
|
2015-10-26 12:55:32 +01:00
|
|
|
|
2016-01-07 18:31:27 +01:00
|
|
|
- Find a file containing a string, in a given directory:
|
2015-10-26 12:55:32 +01:00
|
|
|
|
2015-12-07 00:01:50 +01:00
|
|
|
`mdfind -onlyin {{directory}} {{query}}`
|