Good afternoon,
I'm trying to search a directory sub-tree for a specific string. I use this:
find . -type f -print | xargs grep -l [string] /dev/null
(but without the brackets). This often works. But it sometimes fails when the search string contains "printable" characters other than letters and digits. Examples of both:
bash.32[.Organ]: find . -type f -print | xargs grep -l D-_qS_3KXBA /dev/null ./organ_dir.txt bash.33[.Organ]: find . -type f -print | xargs grep -l -ob9LHPEaKY /dev/null grep: conflicting matchers specified bash.34[.Organ]: find . -type f -print | xargs grep -l "-ob9LHPEaKY" /dev/null grep: conflicting matchers specified bash.35[.Organ]: bash.35[.Organ]: bash.35[.Organ]:
bash.36[.Organ]: find . -type f -print | xargs grep -l '-ob9LHPEaKY' /dev/null grep: conflicting matchers specified bash.37[.Organ]:
How do I get this to work even when the search string includes (especially starts with) printable characters other than digits and letters?