How is it possible to use the GNU find command to match several file types at a time (one search command)?
The man page says:
-type c File is of type c: b block (buffered) special c character (unbuffered) special d directory p named pipe (FIFO) f regular file l symbolic link; this is never true if the -L option or the -follow option is in effect, unless the symbolic link is broken. If you want to search for symbolic links when -L is in effect, use -xtype. s socket D door (Solaris)
and I want to search for files (
f) and symbolic links (
l) and pipe it to another process. How can I search for both at the same time?
I have tried
find -type fl | … find -type f -type l | … find -xtype f -type l | …
I know a workaround would be to use a subshell
(find -type f; find -type l) | …
but I just want to know if it is possible.