Path: utzoo!utgpu!news-server.csri.toronto.edu!rutgers!tut.cis.ohio-state.edu!att!cbnewsc!gregg From: gregg@cbnewsc.att.com (gregg.g.wonderly) Newsgroups: comp.sys.amiga.tech Subject: Re: PIPEs Message-ID: <1990Nov4.150403.28982@cbnewsc.att.com> Date: 4 Nov 90 15:04:03 GMT References: <1990Nov4.072423.408@agate.berkeley.edu> Organization: AT&T Bell Laboratories Lines: 30 From article <1990Nov4.072423.408@agate.berkeley.edu>, by pete@violet.berkeley.edu (Pete Goodeve): > At least this is the case if you insist on a > space preceding it (as you need before '>' redirection), because a pattern > can never BEGIN with an alternation mark. (Quotes and parentheses would > have to be taken into account naturally.) > > list #?.c|???.h | myformatter |myprinter > > Any other problems? If not, I withdraw my objections. I find the UN*X shells' quoting conventions to be quite adequate at avoiding the need to require a SPACE anywhere. If you want something which contains meta characters to become part of a parameter-word, you quote it. That makes it pretty simple to put together whatever you need. grep some-text *.c egrep "some-text|other-text|other-text" *.c etc. Of course the biggest part of this is educating people which characters are special meta-characters which the shell will treat in a special way. I usually just tell people, when you want a character that is not a letter or digit to be a part of a parameter to a program, just quote it. This results in no surprises. -- ----- gregg.g.wonderly@att.com (AT&T bell laboratories)