ParentFull threaddanadam·With sed instead of grep, and probably not much better, but in a single command: cat hello | sed -n '/foo/{ /bar/{ /baz/ p }}'View on HN