From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 95545 invoked by alias); 3 Jan 2018 17:31:17 -0000 Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com Received: (qmail 95527 invoked by uid 89); 3 Jan 2018 17:31:14 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.2 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=ham version=3.3.2 spammy=2.9.0 X-HELO: mail-wm0-f53.google.com Received: from mail-wm0-f53.google.com (HELO mail-wm0-f53.google.com) (74.125.82.53) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 03 Jan 2018 17:31:13 +0000 Received: by mail-wm0-f53.google.com with SMTP id f140so3924012wmd.2 for ; Wed, 03 Jan 2018 09:31:13 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=fY2nhnYVZ2fP2cMCW/7/g3Cd9Ey8qtQBHegqapZgaB0=; b=YaXJ4kW5WfRPizNEsjDEN+D6viDrQaQBSzitZzbaxKqTOF4gpXiq9P5uPIQiSMeoxU IQit9TVCnWPnF6fvjrkJnmNw4plfp14LI3BIqpqRFRBrIUZ0GjTmxpYnP3zQ2352bGlG Qq/qNB8QgN2wv7uIXTFPn0Jam94Mlu9sLsdfzKsPvJHKgyG9qvwYQYHrZfN/sW0UnDsA dRK317D9uYRtKdy3phzqmwpgD2S+tO+2L/DjOUIjdPDfLQDeXVgGT7J/afkY9D+DI2lC LXd+wxuh/nzif5nxcavQ2uEdtrbhYkMGjG/0pfujLsD4lMJCV3UeUgg7xCWh7Myaa+HO 5uMg== X-Gm-Message-State: AKGB3mI0MsSmlHB/eX2X1cd7MfWJsjw8JbexAsbEkCSRwyrt3NvzOcJK t9SJKGgkKaPfkgUfdvOHVCDod4VanmtaQt/affijKw== X-Google-Smtp-Source: ACJfBothdeu13p/cLmvf9q7Nj3amLtmAn8RhK7FHM1wNURX6P32+9kVVfk8pFr0H7lCaR5BTGxyDiW2gJUwfYVsrPlY= X-Received: by 10.80.146.227 with SMTP id l32mr3747047eda.114.1515000671069; Wed, 03 Jan 2018 09:31:11 -0800 (PST) MIME-Version: 1.0 Received: by 10.80.172.230 with HTTP; Wed, 3 Jan 2018 09:31:10 -0800 (PST) From: David Karr Date: Wed, 03 Jan 2018 17:31:00 -0000 Message-ID: Subject: Grep can't match characters before EOL marker without ^M To: The Cygwin Mailing List Content-Type: text/plain; charset="UTF-8" X-IsSubscribed: yes X-SW-Source: 2018-01/txt/msg00012.txt.bz2 My cygwin version appears to be "2.9.0(0.318/5/3)". If I have a text file that has a line that ends with "abc", and I try to grep for "abc$", it doesn't match. I find that it does match "$" and "abc^M$". I've read some of the documentation about line endings in Cygwin. I need to write some scripting that works on both Cygwin and Linux. What do I need to do here? -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple