I am trying to locate a client's pdf file that was saved on an external backup drive, which contains a little over 8000 pdf files and hundreds of folders.
For example, if I want to search all pdf files on drive X: that contains my client's name "Sequoia Group", what are some useful command lines and/or tools to achieve relevant output results?
I'm using MacOS High Sierra, with zsh, I've also installed GNU grep, ack, and pdfgrep via homebrew. However, I haven't been able to find the file yet.
Filename is unkown, since all files were saved as PDF-Backup-0001, PDF-Backup-0002...etc.,
I used the following commands so far with no luck:
#grep -wirl "sequoia group" ./
#pdfgrep -iHncRZ "sequoia group"
#mdfind "sequoia group"
Also, this command line was suggested, however, I am not sure where to put the name, so I replaced /path with the drive's path, and pattern with "sequoia", still did not find any matches
#find /path -iname '*.pdf' -exec pdfgrep pattern {} +
#find /Volumes/X Backup -iname '*.pdf' -exec pdfgrep "sequoia" {} +
pdfgrep -r --include "*.pdf" pattern
and see if it works? You'd run that from the top directory, which is '/Volumes/X Backup' in your case.