From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13280 invoked by alias); 11 Oct 2016 10:58:45 -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 13263 invoked by uid 89); 11 Oct 2016 10:58:44 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_PASS autolearn=ham version=3.3.2 spammy=H*r:ip*192.168.1.101, H*r:LMTP, H*M:post, H*MI:sk:UQ@mail X-HELO: mail.ddt-consult.de Received: from mail.ddt-consult.de (HELO mail.ddt-consult.de) (144.76.157.101) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 11 Oct 2016 10:58:34 +0000 Received: from ddt-filter.ddt-consult.intern (ddt-filter.ddt-consult.intern [192.168.1.116]) by mail.ddt-consult.de (Postfix) with ESMTP id 5CC8930D3B6 for ; Tue, 11 Oct 2016 12:58:32 +0200 (CEST) Received: from mail.ddt-consult.de ([IPv6:::ffff:192.168.1.101]) by ddt-filter.ddt-consult.intern (ddt-filter.ddt-consult.intern [::ffff:192.168.1.116]) (amavisd-new, port 20024) with LMTP id Btdt2QLv8cfH for ; Tue, 11 Oct 2016 12:58:30 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) (Authenticated sender: mks@list-post.mks-mail.de) by mail.ddt-consult.de (Postfix) with ESMTPSA id 9260830D3B3 for ; Tue, 11 Oct 2016 12:58:30 +0200 (CEST) Subject: Re: uniq not working To: cygwin@cygwin.com References: Reply-To: cygwin@cygwin.com From: =?UTF-8?Q?Markus_Sch=c3=b6nhaber?= Message-ID: Date: Tue, 11 Oct 2016 12:54:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.4.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-IsSubscribed: yes X-SW-Source: 2016-10/txt/msg00156.txt.bz2 Am 11.10.2016 um 12:43 schrieb Felipe Vieira: > the uniq program seems to be faulty on my cygwin: > [...] > /tmp » uniq -c u.txt > 1 1 > 1 2 > 1 3 > 1 4 > 1 5 > 1 1 > 1 2 > 1 3 > 1 6 > 1 7 > 1 8 > 1 > /tmp » > > As you can see it does not eliminate duplicate lines. > This file was created with vim. Same results if created with windows notepad. > What am I missing? >From man uniq: | Note: 'uniq' does not detect repeated lines unless they are | adjacent. You may want to sort the input first, or use 'sort -u' | without 'uniq'. -- Regards mks -- 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