It's silly when set up like that. But I still prefer the separate invocations -- they become building blocks. It means I can replace the "cat file" with "echo testdata", it reads nice, and for more complicated scripts, it's easy to format across lines:
zcat /var/log/somdeamon/* \
| grep "simple event like maybe 'error'"
| grep "complicated date expression or whatever"
| some other filter
| summation?
| maybe sort and uniq
I can start that with a simple (z)cat of
one file (rather than the thousands of lines I might want to work on) -- and it doesn't require much arcane knowledge of each of the tools used, for each step.
I do agree that awk might be a little under-appreciated, but if you really feel that way, maybe you should just use snobol.
To me a "wasted cat" clearly states intention: get/feed data. Then the rest of the steps either filter, sum, or manipulate data.
The final thing that makes the "waste"-argument silly, is that Linux[1] has pretty lightweight processes. I'm not sure what the state of the various BSDs are, but it'd surprise if at least FreeBSD hasn't gotten a lot better on this too. Either way, one would think that any text pipeline would be io-bound, not limited by the number of forks...
[1] http://bulk.fefe.de/scalability/