Mark, the following command works for me with bourne shell sh:
sh: ( Work: sh -c 'ppmtoy4m -h 2>&1 | grep 420mpeg2 | wc -l' ) tcsh: ppmtoy4m -h | grep 420mpeg2 |& wc -l ( Work: tcsh -c 'ppmtoy4m -h |& grep 420mpeg2 | wc -l' ) bash: ppmtoy4m -h | grep 420mpeg2 2>&1 | wc -l ( Work: bash -c 'ppmtoy4m -h 2>&1 | grep 420mpeg2 | wc -l' ) thanks Martin > Re: [Mjpeg-users] how can i figure out if ppmtoy4m has a option 420mpeg2 > Hi Martin, > > The output from the help of ppmtoy4m is appearing on stderr not =20 stdout. You will need to redirect stderr through your pipe. > Depending on what shell you are using this is done in different ways. > > tcsh: > ppmtoy4m -h | grep 420mpeg2 |& wc -l > > bash: > ppmtoy4m -h | grep 420mpeg2 2>&1 | wc -l > > Have a search for redirecting stderr for which shell you are using on =20= > > how to redirect stderr. > > Mark > ------------------------------------------------------------------------- SF.Net email is sponsored by: The Future of Linux Business White Paper from Novell. From the desktop to the data center, Linux is going mainstream. Let it simplify your IT future. http://altfarm.mediaplex.com/ad/ck/8857-50307-18918-4 _______________________________________________ Mjpeg-users mailing list Mjpeg-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mjpeg-users