Received: (at 33162) by debbugs.gnu.org; 21 Sep 2020 22:41:32 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Mon Sep 21 18:41:32 2020 Received: from localhost ([127.0.0.1]:56702 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1kKUV2-0002lV-1E for submit <at> debbugs.gnu.org; Mon, 21 Sep 2020 18:41:32 -0400 Received: from zimbra.cs.ucla.edu ([131.179.128.68]:56772) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <eggert@HIDDEN>) id 1kKUV0-0002lD-EV; Mon, 21 Sep 2020 18:41:30 -0400 Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id 1585E1600F9; Mon, 21 Sep 2020 15:41:25 -0700 (PDT) Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10032) with ESMTP id K_OqUUyOwTfU; Mon, 21 Sep 2020 15:41:24 -0700 (PDT) Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id 373961600FD; Mon, 21 Sep 2020 15:41:24 -0700 (PDT) X-Virus-Scanned: amavisd-new at zimbra.cs.ucla.edu Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id Gky3RFvkpohF; Mon, 21 Sep 2020 15:41:24 -0700 (PDT) Received: from [192.168.1.9] (cpe-23-243-218-95.socal.res.rr.com [23.243.218.95]) by zimbra.cs.ucla.edu (Postfix) with ESMTPSA id 058A31600F9; Mon, 21 Sep 2020 15:41:24 -0700 (PDT) Subject: Re: bug#32838: Regression in grep 3.1: Grep '$' matcher no longer works on CRLF files on Windows To: Konstantin Kolinko <knst.kolinko@HIDDEN>, Holger Klene <h.klene@HIDDEN> References: <CABzHfVnYOYDd9v3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1lIZkRvNXMKbWY5bG82WVh4N045Cj0zTGFJCi0tLS0tRU5EIFBHUCBQVUJMSUMg S0VZIEJMT0NLLS0tLS0K Organization: UCLA Computer Science Department Message-ID: <119b7bf4-2336-cc6c-ebc5-8123b16afa84@HIDDEN> Date: Mon, 21 Sep 2020 15:41:23 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: <CABzHfVnYOYDd9v3ENJr63z+qDxfkazXMJ1Sz6tthzaV4+h9DXQ@HIDDEN> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 33162 Cc: 33162 <at> debbugs.gnu.org, 32838 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -3.3 (---) On 9/25/18 1:15 AM, Konstantin Kolinko wrote: > https://github.com/git-for-windows/git/issues/1841 Looking at that downstream bug report, it appears that this is a wishlist request and that there have been no takers for implementing an MS-Windows-specific --strip-trailing-cr option. I have marked Bug#32838 and Bug#33162 as wishlist in the grep bug database.
bug-grep@HIDDEN
:bug#33162
; Package grep
.
Full text available.Paul Eggert <eggert@HIDDEN>
to control <at> debbugs.gnu.org
.
Full text available.Paul Eggert <eggert@HIDDEN>
to control <at> debbugs.gnu.org
.
Full text available.Received: (at submit) by debbugs.gnu.org; 26 Oct 2018 12:53:13 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Fri Oct 26 08:53:13 2018 Received: from localhost ([127.0.0.1]:43285 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1gG1c1-0001MC-JY for submit <at> debbugs.gnu.org; Fri, 26 Oct 2018 08:53:13 -0400 Received: from eggs.gnu.org ([208.118.235.92]:46069) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <h.klene@HIDDEN>) id 1gG1c0-0001Lx-9r for submit <at> debbugs.gnu.org; Fri, 26 Oct 2018 08:53:12 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from <h.klene@HIDDEN>) id 1gG1bt-0004Dd-P2 for submit <at> debbugs.gnu.org; Fri, 26 Oct 2018 08:53:06 -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.6 required=5.0 tests=BAYES_20,FREEMAIL_FROM,XPRIO autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:42355) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from <h.klene@HIDDEN>) id 1gG1bt-0004Cj-Av for submit <at> debbugs.gnu.org; Fri, 26 Oct 2018 08:53:05 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:55126) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from <h.klene@HIDDEN>) id 1gG1bp-0005VP-67 for bug-grep@HIDDEN; Fri, 26 Oct 2018 08:53:05 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from <h.klene@HIDDEN>) id 1gG1RB-0005DW-HN for bug-grep@HIDDEN; Fri, 26 Oct 2018 08:42:04 -0400 Received: from mout.gmx.net ([212.227.17.22]:51383) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from <h.klene@HIDDEN>) id 1gG1RB-0005C6-7q for bug-grep@HIDDEN; Fri, 26 Oct 2018 08:42:01 -0400 Received: from [194.114.104.125] ([194.114.104.125]) by web-mail.gmx.net (3c-app-gmx-bs70.server.lan [172.19.170.215]) (via HTTP); Fri, 26 Oct 2018 14:41:59 +0200 MIME-Version: 1.0 Message-ID: <trinity-94797cc3-9d81-48c9-9826-df1811c4a71c-1540557718943@3c-app-gmx-bs70> From: "Holger Klene" <h.klene@HIDDEN> To: bug-grep@HIDDEN Subject: Pattern partially greps windows line-endings since 3.1 Content-Type: text/plain; charset=UTF-8 Date: Fri, 26 Oct 2018 14:41:59 +0200 Importance: normal Sensitivity: Normal X-Priority: 3 X-Provags-ID: V03:K1:7DolB5m8fcyBgcHvttSweJHictFCOMZO2KtUCY9ZW7fn5+2Z2sJsuxTgDdoWmyWsTX8yF DQ/ExE0hBrU+b5AO+lY7VVrd7ERuo7g0goZwSnXAl6D8POAM5odrCoUMV6/Mj8wbJ9YnJSh2rR2l 7i22YVs13E373IFVuAtDBZMr+FWfa/9taaFzBgknt5DvMBSBw5xoNpxxZyCbA208HSfyOvyVZVb1 oazlyI2r2nzXRPfFcQs0quJE3kThFomPAbmLdFtq9eMbHgapSMRTjDRYIsagmjKAIfPTlO4FuGv0 p0= X-UI-Out-Filterresults: notjunk:1;V01:K0:/b3lZzIuT+M=:j/hYJbTeE2hUv6iNN1rHFn xkxDcIpYgfsgwOmAXnpqEv7ofEzVeE7JjKC6NiZt/PHOKAMcLcKNYc58U7nRyTPrZSg/GFu54 LdjGoWG/HrNMf5iBbXxye8bEvMA6siXMykkC2wEKWKUVtR1u9DrEWKc2SjyIKzJ3w5ZJBuWcS SBSW0Mvst0+MW707ABLN+g8qpKubuaqJu9j/nCVcOjRqBbqFmS1L7W2cI/yjwjHC5S8rB8j4p ByJEi3qTAkV4yRvrtrfqsoZ4Rj8FOQrzL2Nv3KcW/vCcfUEr+I1mvjsiLvEB7nYpf3pVQ0nso 6euN66PPYJ2Yb/lIeqOrMWK9LITq1O20BV3EoQn8NEcpaNnODURlKvskdI0M6KOIvbs3yVFv1 3ObXZNSqP4Nb5+R0dOnZHvBC5JkKbkKOB3bUmpQcO8AdGsXA9vGvdGZpvDycLxW7HN6LqDRrK JIkM9GH9eMRfauQ/bLsN0+XyNF/qAy8kZWUEoXPF+NwOc5e/0nbC X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -3.5 (---) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -5.1 (-----) Hello! I think, I may have stumbled upon a bug in gnu-grep version 3.1 which was not present in 3.0 and 2.6.3 Steps to reproduce: A) generate test-file: printf "a --\r\nb --\nc --\rd --\n\r" > test.txt B) check test-file: md5sum.exe test.txt e3ef5d742eee3a7f326bc7b4b391cc42 *test.txt C) run old grep 3.0 or 2.6.3: $ grep -ce '--[^ -]' test.txt 1 $ grep -ne '--[^ -]' test.txt 3:c --d -- D) run new grep 3.1: $ grep -ce '--[^ -]' test.txt 2 $ grep -ne '--[^ -]' test.txt d -- It looks as if the 3.1 has an issue with alternative line-ending styles sometimes matched as part of the pattern: a --\r\n (windows) is messed around b --\n (unix) seems to work OK c --\r just for completenes d --\n\r just for completenes You can modify the printf statement to generate each test-case into it's own file. b and d are equally not found, c is always found. The behavior changed for a: [^ -] now matches the \r in 3.1 which was ignored in older versions. Thanks Holger PS: This version of grep was distributed along with git-bash for Windows 64bit https://github.com/git-for-windows/git/releases/download/v2.19.1.windows.1/Git-2.19.1-64-bit.exe grep (GNU grep) 3.1 GNU bash, version 4.4.19(2)-release (x86_64-pc-msys) git version 2.19.1.windows.1
"Holger Klene" <h.klene@HIDDEN>
:bug-grep@HIDDEN
.
Full text available.bug-grep@HIDDEN
:bug#33162
; Package grep
.
Full text available.
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997 nCipher Corporation Ltd,
1994-97 Ian Jackson.