From owner-freebsd-stable@FreeBSD.ORG Sat Jul 13 16:20:39 2013 Return-Path: Delivered-To: stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 51BB944E for ; Sat, 13 Jul 2013 16:20:39 +0000 (UTC) (envelope-from kob6558@gmail.com) Received: from mail-ob0-x233.google.com (mail-ob0-x233.google.com [IPv6:2607:f8b0:4003:c01::233]) by mx1.freebsd.org (Postfix) with ESMTP id 1F45B182D for ; Sat, 13 Jul 2013 16:20:39 +0000 (UTC) Received: by mail-ob0-f179.google.com with SMTP id xk17so12498065obc.10 for ; Sat, 13 Jul 2013 09:20:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=iNtEb/bwjSaLIlP7P4aApXI+ERyF56oSGc//pXHcLvM=; b=pGumE316QSt1o9AJSKQU9qmUYbOeMRx0xxNit4ouNhi/fW/0LlyWtGrtmUsCv/gpL7 hnoVBmbAKk8U40Rk4EnRWJffjq/I1lO+Zi302Ey94pmFvCWhlBD+IwWCTCkS0L+338QI 4cMPdQHaJ4863oRJYgg5+YKWCyNhpEhDHiNCHY1ugOjI6Y5bO06suNZmLNto7Mv5n8Fg 1S7JVTcILVSXdK98zmKxPrFcKAigAOloOsWiwAGRZQCOpNxnGQ5mWMUPdHIXkA9KkCe5 bLxBwe32RSxdGAZ+INjatMwyy/C4zndrrRnI0EUqtQhKYdJGtksS3R2auFq7yqgKfOHD FF7w== MIME-Version: 1.0 X-Received: by 10.60.102.202 with SMTP id fq10mr17432760oeb.42.1373732438190; Sat, 13 Jul 2013 09:20:38 -0700 (PDT) Sender: kob6558@gmail.com Received: by 10.76.112.212 with HTTP; Sat, 13 Jul 2013 09:20:38 -0700 (PDT) In-Reply-To: <2813184.tAUhP2F1j4@alex.super> References: <8704004.oreYQuEkVL@alex.super> <2813184.tAUhP2F1j4@alex.super> Date: Sat, 13 Jul 2013 09:20:38 -0700 X-Google-Sender-Auth: TaNJ4SxGu8NHClq0As3gws-4Tfk Message-ID: Subject: Re: ls -U don't work? From: Kevin Oberman To: "Alex V. Petrov" Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.14 Cc: "freebsd-stable@freebsd.org Stable" , Sergey Kandaurov X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 13 Jul 2013 16:20:39 -0000 On Sat, Jul 13, 2013 at 3:30 AM, Alex V. Petrov wrot= e: > =D0=92 =D0=BF=D0=B8=D1=81=D1=8C=D0=BC=D0=B5 =D0=BE=D1=82 13 =D0=B8=D1=8E= =D0=BB=D1=8F 2013 13:45:30 =D0=92=D1=8B =D0=BD=D0=B0=D0=BF=D0=B8=D1=81=D0= =B0=D0=BB=D0=B8: > > 2013/7/13 Alex V. Petrov : > > > subj: > > > ls -Ul > > > > So, what's the problem? Looking at code, > > I'd suggest to try adding -t to actually enable sorting, > > otherwise it just prints dates but not sorts. > > > > > total 0 > > > -rw-r--r-- 1 alex alex 0 13 =D0=B8=D1=8E=D0=BB 15:26 000 > > > -rw-r--r-- 1 alex alex 0 13 =D0=B8=D1=8E=D0=BB 15:25 111 > > > -rw-r--r-- 1 alex alex 0 13 =D0=B8=D1=8E=D0=BB 15:25 222 > > > -rw-r--r-- 1 alex alex 0 13 =D0=B8=D1=8E=D0=BB 15:25 333 > > > > -t enables sorting (by modified date by default), > > -U further specifies to sort by birth time. > > What is the meaning of '-U'?I thought '-U' =3D '-tr' > > man ls: > "-U Use time when file was created for sorting or printing." > > ----- > Alex V. Petrov > No, '-U' tells ls(1) to use ctime for all timestamps. By default it uses mtime. So 'ls -U' will print ctime, but to sort by ctime you need 'ls -Ut' or 'ls -Utr'. --=20 R. Kevin Oberman, Network Engineer E-mail: rkoberman@gmail.com