I think you simply miss --ignore-case in second grep (first grep find it
but dont convert the case so the second can't find the pattern)
Try add -i to the second grep.
--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
--- Chris Evans <[EMAIL PROTECTED]> wrote:
> #!/bin/bash
> /usr/bin/find /usr/lib/ecartis/lists/ -name users -print \
> -exec grep --ignore-case "$1" {} \; | grep -B 1 "$1"
Odd, it works fine for me. Are you sure there is no other factor?
-- Thomas Adam
=
"The Linux Weekend Mechanic" -
Perhaps I am looking straight through things, if so, I'm sorry. I
have effectively a one liner shell script that I want to run to see
if any text (typically an Email address) is in any file named "users"
in any directory below a particular directory, easy I thought:
#!/bin/bash
/usr/bin/find /
3 matches
Mail list logo