From owner-freebsd-arch Sun Mar 31 20:15:18 2002 Delivered-To: freebsd-arch@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 821) id 7878337B400; Sun, 31 Mar 2002 20:15:13 -0800 (PST) Date: Sun, 31 Mar 2002 20:15:13 -0800 From: John De Boskey To: Arch List Subject: /bin/ls -T option logic/doc Message-ID: <20020331201513.A55590@FreeBSD.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hi, The -T option to ls specifies to display complete time information. However, this option only has effect when the -l (ell) option is also specfied. Two alternatives: - Update the manpage to reflect the dependancy as is already done with other options. - Update the -T option processing to automatically imply the -l option. I believe the manpage update is probably the safest, but I don't know if it is the most correct. I can't seem to find any standards doc on this issue related to -T. Pointers? Thanks! John ps: Also noted in the ls.1 diff is a spelling correction which can be done regardless of -T. Index: ls.1 =================================================================== RCS file: /home/ncvs/src/bin/ls/ls.1,v retrieving revision 1.62 diff -u -r1.62 ls.1 --- ls.1 9 Jan 2002 13:29:39 -0000 1.62 +++ ls.1 1 Apr 2002 03:51:35 -0000 @@ -137,8 +137,12 @@ .It Fl R Recursively list subdirectories encountered. .It Fl T -Display complete time information for the file, including -month, day, hour, minute, second, and year. +When used with the +.Fl l +(lowercase letter +.Dq ell ) +option, display complete time information for the file, including +month, day, hour, minute, second, and year. .It Fl W Display whiteouts when scanning directories. .It Fl Z @@ -167,7 +171,7 @@ .Pq Fl l format output. .It Fl h -When used wih the +When used with the .Fl l option, use unit suffixes: Byte, Kilobyte, Megabyte, Gigabyte, Terabyte and Petabyte in order to reduce the number of digits to three or less Index: ls.c =================================================================== RCS file: /home/ncvs/src/bin/ls/ls.c,v retrieving revision 1.56 diff -u -r1.56 ls.c --- ls.c 19 Feb 2002 00:05:50 -0000 1.56 +++ ls.c 1 Apr 2002 03:53:50 -0000 @@ -263,6 +263,8 @@ break; case 'T': f_sectime = 1; + f_longform = 1; + f_singlecol = 0; break; case 't': f_timesort = 1; To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message