using grep with pipe and ampersand to filter errors from find
Posted
by
HKK
on Ask Ubuntu
See other posts from Ask Ubuntu
or by HKK
Published on 2011-02-05T19:25:17Z
Indexed on
2011/02/07
7:33 UTC
Read the original article
Hit count: 308
I am using cygwin to find a file on the cygdrive.
However I need to suppress the permission denied messages (otherwise the results get hidden in the error messages). The following command works:
find -name 'myfile.*' |& grep -v "Permission denied"
I don't understand why the ampersand needs to be put into this command, would have expected this to work but it doesn't.
find -name 'myfile.*' | grep -v "Permission denied"
Please explain the meaning of the ampersand.
© Ask Ubuntu or respective owner