On Mon, 2003-02-24 at 17:36, Stuart Jansen wrote: > No, it isn't. A quick test will tell you that. Likewise, it _does_ > matter where you put the 2>&1. It has to to pull off more advanced > tricks. (Creating new filedescriptors and using them as multiple pipes, > etc.)
That is true. > > When at all possible, I try to test before answering a question. I > wouldn't have said the second solution didn't work if I hadn't seen it > fail. That would be too much work. :) I had done this before and it worked, but that could have been because I was simply redirecting using > and 2>, not using pipes. I stand corrected. > > -- > [previous directory: unavailable ] > [patience: /home/sjansen ] > bash:sjansen()$ ls -l /root/ | grep hi 2>/dev/null > ls: /root/: Permission denied > > [previous directory: unavailable ] > [patience: /home/sjansen ] > bash:sjansen()$ ls -l /root/ 2>/dev/null | grep hi > > [previous directory: unavailable ] > [patience: /home/sjansen ] > bash:sjansen()$ > -- > > > Note that in the case of the original poster he's using csh, which > > doesn't have the same syntax for redirection and thus 2> is illegal. > > Anyone know how to do it? > > Unfortunately, I don't. If bash isn't available, sh always is. It's less advanced, > but in this case good enough. -- Michael Torrie <[EMAIL PROTECTED]> ____________________ BYU Unix Users Group http://uug.byu.edu/ ___________________________________________________________________ List Info: http://phantom.byu.edu/cgi-bin/mailman/listinfo/uug-list
