Path: utzoo!attcan!uunet!husc6!mailrus!ames!necntc!ima!trb From: trb@ima.ISC.COM (Andrew Tannenbaum) Newsgroups: comp.unix.questions Subject: Re: grep replacement Message-ID: <1039@ima.ISC.COM> Date: 31 May 88 16:10:41 GMT References: <7882@alice.UUCP> <2450011@hpsal2.HP.COM> <54818@sun.uucp> Reply-To: trb@ima.UUCP (Andrew Tannenbaum) Organization: Interactive Systems, Boston, MA Lines: 17 > I seem to remember some indication that the new BTL research "grep" > would have a flag to tell it always to give the file name). I have always wanted to be able to tell grep to NOT print the file names on a multi-file grep. Let's say I want a phone number script - usually a simple grep - but if I want to store the numbers in multiple files (e.g. mine and my departments), then the output contains unsightly filenames. This has always struck me as opposite to the UNIX philosophy of having a filter provide output that is useful as data. I would like the option to go to the next file after first match (regardless of which other options are present). Also, I would like to print a region other than line on a match. It would be nice to delimit the patterns using regexps, as "-n,+n" and "?^$?,/^$/" (among others) would be useful. Andrew Tannenbaum Interactive Boston, MA +1 617 247 1155