From owner-freebsd-current Sun Nov 15 08:28:56 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id IAA10001 for freebsd-current-outgoing; Sun, 15 Nov 1998 08:28:56 -0800 (PST) (envelope-from owner-freebsd-current@FreeBSD.ORG) Received: from helios.dnttm.ru (dnttm-gw.rssi.ru [193.232.0.205]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id IAA09991 for ; Sun, 15 Nov 1998 08:28:51 -0800 (PST) (envelope-from dima@tejblum.dnttm.rssi.ru) Received: (from uucp@localhost) by helios.dnttm.ru (8.9.1/8.9.1/IP-3) with UUCP id TAA29577; Sun, 15 Nov 1998 19:26:32 +0300 Received: from tejblum.dnttm.rssi.ru (localhost [127.0.0.1]) by tejblum.dnttm.rssi.ru (8.9.1/8.9.1) with ESMTP id TAA04794; Sun, 15 Nov 1998 19:26:17 +0300 (MSK) (envelope-from dima@tejblum.dnttm.rssi.ru) Message-Id: <199811151626.TAA04794@tejblum.dnttm.rssi.ru> X-Mailer: exmh version 2.0gamma 1/27/96 To: Wolfram Schneider cc: current@FreeBSD.ORG Subject: Re: sort option for find In-reply-to: Your message of "Sun, 15 Nov 1998 14:05:18 +0100." <19981115140518.A2166@panke.de.freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Sun, 15 Nov 1998 19:26:16 +0300 From: Dmitrij Tejblum Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Wolfram Schneider wrote: > > > > That depends on what do you call "lexicographical order". How do you > > compare "foo-1.2.3/Makefile" and "foo/Makefile", for example? (Anyhow, > > I compare the file "foo-1.2.3" with the file "foo" and > "foo-1.2.3" is greater. The directory "foo" will be visited first. > > I don't sort the output - I change the order > of the traversal of the file hierarchy. As a side effect, the output > will be sorted on a per directory basis. Sure, but did you noticed that strcmp("foo-1.2.3/Makefile", "foo/Makefile") < 0? That is, 'find -s' and 'find | sort' give different results? Is it ok? Dima To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message