how to tell "ls" output date in digital

Chad Perrin perrin at apotheon.com
Thu Sep 9 17:10:42 UTC 2010


On Thu, Sep 09, 2010 at 10:29:08AM -0400, Jerry McAllister wrote:
> On Thu, Sep 09, 2010 at 01:11:39PM +0000, Pala, Santosh wrote:
> 
> > Hi Andrew,
> > 
> > The ls command with -E switch will give the required output. 
> 
> Doesn't for me.
> Says -E is an illegal option.

It works with AT&T's version of ls, apparently.  I'm pretty sure it
doesn't work with either BSD ls or GNU ls, though, so I'm not sure how it
ended up being mentioned in this discussion.


> 
> Running FreeBSd 8.1 stock ls.
> 
> On the other hand,   ls -lD "%F %T %Z"   does nicely.

. . . and you can easily alias that to lsd for easier use (and a
chuckle).

Note that this doesn't work with GNU ls, because Stallman and MacKenzie
in their infinite wisdom decided GNU ls needed -D to produce output
tailored to some Emacs functionality.

-- 
Chad Perrin [ original content licensed OWL: http://owl.apotheon.org ]
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-questions/attachments/20100909/63ba2921/attachment.pgp


More information about the freebsd-questions mailing list