Re:Unix: When pipes get names
by derleth on Tuesday October 08, 2013 @08:11PM
(#6518717)
Does:
not work with named pipes?
[ Parent
| on HN ]
It works fine.
The advantage to
cat foo | sort | uniq -u
is that it is (marginally) easier to drop in another filter in front of sort.This argument is less strong in the face of:
<foo sort | uniq -u
(redirections can be at the beginning too.)Also: sort -u instead of sort|uniq.
It's still a reason to disprefer the form that was given. I don't see any reason to prefer the cat version over yours, except habits, though. That said, there's only weak reason to avoid the cat.