On 09/02/2018, at 11:27, Sam Hathaway <[email protected] <mailto:[email protected]>> wrote: > On 2 Sep 2018, at 10:26, Christopher Stone wrote: > I think it will be much slower than Perl on a multi-GB file. > > And it might choke > > Can you say more about this? I thought grep was set up to work efficiently > with files of any size. >
Hey Sam, I've personally had some issues grepping large files in the past, but it's been quite a while – and I don't recall all the details. My best recollection is (with big files): Grep is slow. Grep can choke and completely fail. https://www.networkworld.com/article/2706756/big-data/groping-through-big-data-with-grep.html <https://www.networkworld.com/article/2706756/big-data/groping-through-big-data-with-grep.html> In particular see: “The other grep issue that you might not be expecting with grep is that it gives up when a file reaches a certain size and complexity.” Google: grep bogs down with very large files <https://www.google.com/search?num=50&newwindow=1&source=hp&ei=J26NW4yFOM_2swXd54e4Dw&q=grep+bogs+down+with+very+large+files&btnK=Google+Search&oq=grep+bogs+down+with+very+large+files&gs_l=psy-ab.3...252.19448..19978...14.0..1.159.4600.50j5......0....1j2..gws-wiz.....0..0j35i39j0i131j0i20i263j0i20i263i264j0i131i20i264j0i20i264j0i10j0i22i30j0i22i10i30j33i21j33i160.GBLdhnGnGVA> If you must use grep then you really want to install gnu grep, because the stock version on macOS is somewhere around eight years old. MacPorts and Homebrew both have it. port info grep brew info grep But I make no guarantees about what size files they'll handle. -- Best Regards, Chris -- This is the BBEdit Talk public discussion group. If you have a feature request or need technical support, please email "[email protected]" rather than posting to the group. Follow @bbedit on Twitter: <https://www.twitter.com/bbedit> --- You received this message because you are subscribed to the Google Groups "BBEdit Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at https://groups.google.com/group/bbedit.
