On 11/03/15 20:56, Peng Yu wrote:
> Hi,
>
> Mac OS X's ls has an option -e which related with ACLs. But coreutils'
> ls does not have this option, which make coreutils' ls not a complete
> replacement of Mac OS X's ls. Is it possible to add this feature to
> coreutils' ls?
There are many "non traditional" attributes that may be present.
ACLs, security contexts, extended attributes, capabilities, file system
specific attrs, ...
OSX has added the -@ and -e options to output extended attributes
and ACLs respectively (on a separate line):
$ /bin/ls -@eld /System
drwxr-xr-x+ 4 root wheel 136 Oct 9 07:53 /System
0: group:everyone deny delete
$ /bin/ls -@eld /Volumes
drwxrwxrwt@ 3 root admin 102 Mar 9 18:00 /Volumes
com.apple.FinderInfo 32
0: group:everyone deny
add_file,add_subdirectory,directory_inherit,only_inherit
I do see some benefit to listing these attributes inline,
however I'm not convinced that we should add those, given that
there are separate tools to parse and display these items.
I.E. getfacl, getcap, getfattr, lsattr etc.
Given more attributes may be added in future, this is the most extendible
scheme.
thanks,
Pádraig.