Closed jdlehman closed 9 years ago
Do you know the pipe operator was invented in 1973 ?
mocha-phantomjs -R dot | node ./myTransformer.js
@nathanboktae Great technical point. But please be more empathetic with the responses. Even if Jonathan was not a co-worker of mine, we should be nice. Sometimes people hit things from the wrong angle and that is OK.
A friendly feedback can go a long way to establishing good open source relationships. I've made a few mistakes like this before, but please try to keep this project and our faces + to those that want to help. Thanks.
True Ken, I should be. PRs are like publicity, it's always good that people want to contribute.
@jdlehman Apologies for the snappiness. Keeping to the spirit of the single responsibility principle, there is no reason to have this concern in when shells, and really anything that executes a process can pipe streams in just fine.
@nathanboktae No problem, maintaining OSS isn't easy. I definitely agree with you that piping with the shell is the better way to go. I got so caught up in other details with what I was trying to do that the obvious solution escaped me. Thanks for pointing that out.
This allows users to transform stdout/stderr streams, which enables things like source map support. These transforms work like
hooks
, except they are expected to be valid arguments topipe
. When these arguments are not provided, data passes through to stdout/stderr unchanged.Source map support using sourcemap-transformer: