X-Recipient: archive-cygwin AT delorie DOT com DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:subject:to:references:from:message-id:date :mime-version:in-reply-to:content-type; q=dns; s=default; b=Ht2f zdTEq4w2t3QnTni+KugiefOmp3PGTTBjoNH/w6FXQv8u6HQdtNzBzY84L1ORcN2r sqXDu+j6vk6psI66FMO5dK6BaMEnhBtW2PK5R86AfcmddZ0bwPTkyXF0zaU9O+Bw Rv9HVWNBmCusVALfYXNNINdQdtygoTPrne7voNk= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:subject:to:references:from:message-id:date :mime-version:in-reply-to:content-type; s=default; bh=i9aaAtVOlR Yc4HAME0mukiUyW9Q=; b=W4kezBfjVTUXk5kOWH7MVxzdUhAJ+uhuAf142LqtBq B7yBDLnYAPh20reGi9/9Kz+qQTsfns9hH2n26GEujgDEkOLaMrcolvXxV4U8XR3f FiuQxzNV3wgn/Umt8ukSP9qzQQu8xAnDQRdC49BvUIuQ7WTGQjWdTzTRxLJ5kNtS 4= Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-0.9 required=5.0 tests=BAYES_00,KAM_LAZY_DOMAIN_SECURITY,RP_MATCHES_RCVD,SPF_HELO_PASS autolearn=no version=3.3.2 spammy=complaining, coordinated, claims, website X-HELO: mx1.redhat.com DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com B3A306128B Authentication-Results: ext-mx06.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx06.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=eblake AT redhat DOT com Subject: Re: gawk 4.1.4: CR separate char for CRLF files To: cygwin AT cygwin DOT com References: <004401d3109c$2dcb09e0$89611da0$@gmx.net> <598a47fc DOT 5501ca0a DOT 5476f DOT 0305 AT mx DOT google DOT com> <004701d310a9$372363e0$a56a2ba0$@gmx.net> <001001d310ea$ceeee230$6ccca690$@gmx.net> From: Eric Blake Openpgp: url=http://people.redhat.com/eblake/eblake.gpg Message-ID: <391b0ca2-e495-a908-160a-6d95492f526f@redhat.com> Date: Wed, 9 Aug 2017 06:03:33 -0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1 MIME-Version: 1.0 In-Reply-To: <001001d310ea$ceeee230$6ccca690$@gmx.net> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="ivNsrFqKJrSFhLeSQhaD5ATs3lHxdcMcx" X-IsSubscribed: yes --ivNsrFqKJrSFhLeSQhaD5ATs3lHxdcMcx Content-Type: multipart/mixed; boundary="OGEGRI9r5gcQAJ9PXR73Gn53pLUCJ4P4J"; protected-headers="v1" From: Eric Blake To: cygwin AT cygwin DOT com Message-ID: <391b0ca2-e495-a908-160a-6d95492f526f AT redhat DOT com> Subject: Re: gawk 4.1.4: CR separate char for CRLF files References: <004401d3109c$2dcb09e0$89611da0$@gmx.net> <598a47fc DOT 5501ca0a DOT 5476f DOT 0305 AT mx DOT google DOT com> <004701d310a9$372363e0$a56a2ba0$@gmx.net> <001001d310ea$ceeee230$6ccca690$@gmx.net> In-Reply-To: <001001d310ea$ceeee230$6ccca690$@gmx.net> --OGEGRI9r5gcQAJ9PXR73Gn53pLUCJ4P4J Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: quoted-printable On 08/09/2017 03:37 AM, Jannick wrote: > Which is a pretty much of a pain when there is no easy fallback solution > provided in case a major change is applied. E.g. for sed - if I understand > the reference to sed in https://cygwin.com/ml/cygwin/2017-08/msg00033.html > correctly - a separate switch '-b' is added. Incorrect. 'sed -b' has always existed, but did NOT do what you wanted (it forced CR to be treated as a separate character; where what you want is to ignore CR if it appears before LF). In fact, the coordinated change made back in February to all of grep, sed, and awk, was that all three programs now default to what used to be possible only through 'sed -b', because silently stripping CR can corrupt data when you are not expecting it, while requiring the user to explicitly strip CR when they know they are working with CRLF line endings is less magic (fewer downstream patches, and more obvious in looking at a script that the script knows what it is doing). If your data lives on a text mount (instead of a binary mount), then you still get CR stripping for free. If your data comes from a pipeline rather than the file system, then you can add a d2u or other CR-stripping tool in the pipeline. > This is - to say the least - unpleasant in the light of what Cygwin claims > to be, namely 'a large collection of GNU and Open Source tools which prov= ide > functionality similar to a Linux distribution on Windows' (from the top of > the start website www.cygwin.com). On Linux, nothing strips CR automatically. So on Cygwin, we behave the same - nothing strips CR automatically on binary mounted data. And the fact that the change was made AND ANNOUNCED back in February, but you are now only 6 months later complaining about it, is telling. --=20 Eric Blake, Principal Software Engineer Red Hat, Inc. +1-919-301-3266 Virtualization: qemu.org | libvirt.org --OGEGRI9r5gcQAJ9PXR73Gn53pLUCJ4P4J-- --ivNsrFqKJrSFhLeSQhaD5ATs3lHxdcMcx Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEzBAEBCAAdFiEEccLMIrHEYCkn0vOqp6FrSiUnQ2oFAlmK7AUACgkQp6FrSiUn Q2os0Qf/b6gwTseRCG1Cz49iqhabbdPz9gd2YTwvXQRwdge6QR+o9+Qyc0OFrLg1 jwV9ESZ0gU07Qv4l2wpHdKFzLlMV+I/mdAd7Fmb03TBtgiAmzuFf++dYxRGHMI1k qN7v3TdmZKtmdfpKhxxz/jlV8J3HhTkq2YgSvT74jVYg3ozOYQ8c8p+IKFRVS/VV jVvMaST9xHBhYynz4dN451JuIu/O5pvngjE/gcFb018VbknP+w88Wat7AYsxCerA PGJ9byAe1vgohkQfZuMDi1DVlxsJeRK2XFYrLL4GQmDMH9KFh+qJ71FWD0dM1i27 PmWM5DhCHCu2rUhVE+N8AQLc3ISxTQ== =pXp/ -----END PGP SIGNATURE----- --ivNsrFqKJrSFhLeSQhaD5ATs3lHxdcMcx--