From unknown Wed Jun 18 00:30:16 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#17687 <17687@debbugs.gnu.org> To: bug#17687 <17687@debbugs.gnu.org> Subject: Status: enhancement request: contiguous lines Reply-To: bug#17687 <17687@debbugs.gnu.org> Date: Wed, 18 Jun 2025 07:30:16 +0000 retitle 17687 enhancement request: contiguous lines reassign 17687 grep submitter 17687 al1chevee@yahoo.fr severity 17687 wishlist thanks From debbugs-submit-bounces@debbugs.gnu.org Wed Jun 04 11:37:57 2014 Received: (at submit) by debbugs.gnu.org; 4 Jun 2014 15:37:58 +0000 Received: from localhost ([127.0.0.1]:44088 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1WsDGD-0007sz-Tf for submit@debbugs.gnu.org; Wed, 04 Jun 2014 11:37:57 -0400 Received: from eggs.gnu.org ([208.118.235.92]:49534) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1WsARb-0001Qv-Av for submit@debbugs.gnu.org; Wed, 04 Jun 2014 08:37:31 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WsARO-0005UK-97 for submit@debbugs.gnu.org; Wed, 04 Jun 2014 08:37:22 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,FREEMAIL_FROM, HTML_MESSAGE,T_DKIM_INVALID autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:34015) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WsARO-0005UG-5u for submit@debbugs.gnu.org; Wed, 04 Jun 2014 08:37:14 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:51219) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WsARG-0004rO-Kl for bug-grep@gnu.org; Wed, 04 Jun 2014 08:37:14 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WsAR9-0005S5-3f for bug-grep@gnu.org; Wed, 04 Jun 2014 08:37:06 -0400 Received: from nm21-vm5.bullet.mail.ir2.yahoo.com ([212.82.97.2]:47202) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WsAR8-0005Ro-OY for bug-grep@gnu.org; Wed, 04 Jun 2014 08:36:59 -0400 Received: from [212.82.98.52] by nm21.bullet.mail.ir2.yahoo.com with NNFMP; 04 Jun 2014 12:36:57 -0000 Received: from [212.82.98.100] by tm5.bullet.mail.ir2.yahoo.com with NNFMP; 04 Jun 2014 12:36:57 -0000 Received: from [127.0.0.1] by omp1037.mail.ir2.yahoo.com with NNFMP; 04 Jun 2014 12:36:57 -0000 X-Yahoo-Newman-Property: ymail-3 X-Yahoo-Newman-Id: 448021.62192.bm@omp1037.mail.ir2.yahoo.com Received: (qmail 49699 invoked by uid 60001); 4 Jun 2014 12:36:57 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.fr; s=s1024; t=1401885417; bh=msmBohV9KBTMqCEsFxVwvxKG318E51CdKu7zU5rI42o=; h=Message-ID:Date:From:Reply-To:Subject:To:MIME-Version:Content-Type; b=YfVTUulwBmEgEXoSMW4R2TxaJVg2oHhuZt5e16TL9VmI+jW8yA8jUVAjZhxxVgrfBfHPd4jri3FvYFfw3p9trPAHMhh/wea4cqUsbgu5vqdTkA6vgtOtkx+MOPaWNgwjQhHoI7JJ7SRdb4nyKkCvgDUPwAUTWQVNKwg+4V+rRMw= X-YMail-OSG: X3OSpmAVM1nWANA0sD5oTRsts14xTbwuE2FrQvu2eveuYDg DSFGblBrxWmK8MLU6oJAG0u9LzBtL1YGUXuPSgPxxbJCWuxOlyc8bvR0g_Gg gjgJcPRKGWTRWPGYeen.A50EnjYVfl8zEChtiKIOllHDesXA13gv0uyzmwn2 4zGiqENzbeWnKVIcYWtmf3AaaZU8yMbNe5tVVw87HEiFcbnPFkstZ5i2blzz m6aKbSp4bcRINTZvM1dTArSPr_W9CHFM1lcTaADLpa0Vnwy0h2Eck8gZnE_4 VfpzRXgSIc1x6S4RYz_i7X57w545oPZUc1SmsfqPuwcW8.XfWT2o6gPrgGnG PRCTPljZG8u8AEXjiZ7Treq5lAfe_l_w5G9eD08CfXMLaoG1PiZ7zlXL8eG8 ALd3DYgb64pMJ4sPSOrEnJJHzgiBUPMS58HRTNloPmIDRrthBzm_jbQdbHiX hvHCAtXpJZq0ozQWjOdPLj7G4ljTedUS.5zgRyaGAiQcL_zR4llFm6ao_j6C e3f0fqu.d9b6SnbaH9NZElLyaxjH_EaFzu.2BBpWqQg0_4WsLRw-- Received: from [128.179.67.75] by web172503.mail.ir2.yahoo.com via HTTP; Wed, 04 Jun 2014 13:36:56 BST X-Rocket-MIMEInfo: 002.001, RGVhciBBbGwsCgpIb3BlIHRoaXMgbWFpbCBmaW5kcyB5b3Ugd2VsbCBhbmQgdGhhdCBpdHMgY29udGVudCByYWlzZXMgc29tZSBpbnRlcmVzdCBpZiBpdCBjYW4gaGVscCB0aGUgZ3JlcCB1c2VycyBjb21tdW5pdHkuCgpHaXZlbiB0aGF0IEkgdXNlIHZlcnkgb2Z0ZW4gZ3JlcCBvbiBsYXJnZSBmaWxlcywgSSByZWFsaXplZCBob3cgdXNlZnVsIHRoZSBvcHRpb24gJy1tYXgtbGluZScgY2FuIGJlLiBOZXZlcnRoZWxlc3MsIEkgZm91bmQgdGhhdCB0aGUgZm9sbG93aW5nIGVuaGFuY2VtZW50IGNvdWxkIGJlIG8BMAEBAQE- X-Mailer: YahooMailWebService/0.8.188.663 Message-ID: <1401885416.8825.YahooMailNeo@web172503.mail.ir2.yahoo.com> Date: Wed, 4 Jun 2014 13:36:56 +0100 (BST) From: al1chevee@yahoo.fr Subject: enhancement request: contiguous lines To: "bug-grep@gnu.org" MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="1665649608-1788963278-1401885416=:8825" X-detected-operating-system: by eggs.gnu.org: FreeBSD 9.x X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Wed, 04 Jun 2014 11:37:51 -0400 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list Reply-To: al1chevee@yahoo.fr List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -5.0 (-----) --1665649608-1788963278-1401885416=:8825 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Dear All,=0A=0AHope this mail finds you well and that its content raises so= me interest if it can help the grep users community.=0A=0AGiven that I use = very often grep on large files, I realized how useful the option '-max-line= ' can be. Nevertheless, I found that the following enhancement could be of = interest for faster processing and hence develop the use of grep:=0A=0Aenha= ncement concept: in addition to the current --max-count=3Dnum option which = takes a numerical input, one could imagine another possibility (like --max-= count=3D"contiguous") which would only retrieve contiguous matching lines s= ince the first match.=0A=0Aadvantages: the current --max-count option impro= ves the speed of the search with an early stop (after n matches) but it ass= umes the user knows exactly the number of lines to look into. With the "con= tiguous" option, the search provides all contiguous searches and then stops= .=0A=0Aremark: this enhancement does not aim to compete with a "database" a= pproach especially for time-serie management, but still many large files ca= n have for example timestamps and using this option would accelerate the se= arches in sorted files thanks to the early stop.=0A=0AAgain, if my enhancem= ent request is redundant with a former one already proposed or does not fit= in the grep approach, please forgive me.=0A=0AHave a nice day and thanks a= gain for the great work.=0A=0AAlain --1665649608-1788963278-1401885416=:8825 Content-Type: text/html; charset=utf-8 Content-Transfer-Encoding: quoted-printable
Dear All,

Hope thi= s mail finds you well and that its content raises some interest if it can h= elp the grep users community.

Given that I use very often g= rep on large files, I realized how useful the option '-max-line' can be. Ne= vertheless, I found that the following enhancement could be of interest for= faster processing and hence develop the use of grep:

enhan= cement concept: in addition to the current --max-count=3Dnum option which t= akes a numerical input, one could imagine another possibility (like --max-c= ount=3D"contiguous") which would only retrieve contiguous matching lines since the first match.

advantages: the current --max-count option improves the speed of the searc= h with an early stop (after n matches) but it assumes the user knows exactl= y the number of lines to look into. With the "contiguous" option, the searc= h provides all contiguous searches and then stops.

remark: = this enhancement does not aim to compete with a "database" approach especia= lly for time-serie management, but still many large files can have for exam= ple timestamps and using this option would accelerate the searches in sorte= d files thanks to the early stop.

Again, if my enhancement = request is redundant with a former one already proposed or does not fit in = the grep approach, please forgive me.

Have a nice day and thanks again for the great= work.

Alain
--1665649608-1788963278-1401885416=:8825--