diff options
Diffstat (limited to 'bin/ls/ls.1')
-rw-r--r-- | bin/ls/ls.1 | 50 |
1 files changed, 30 insertions, 20 deletions
diff --git a/bin/ls/ls.1 b/bin/ls/ls.1 index ef412dd2927d..9d4c55b9b17d 100644 --- a/bin/ls/ls.1 +++ b/bin/ls/ls.1 @@ -29,10 +29,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" @(#)ls.1 8.7 (Berkeley) 7/29/94 -.\" $FreeBSD$ -.\" -.Dd August 31, 2020 +.Dd February 21, 2024 .Dt LS 1 .Os .Sh NAME @@ -40,7 +37,7 @@ .Nd list directory contents .Sh SYNOPSIS .Nm -.Op Fl ABCFGHILPRSTUWZabcdfghiklmnopqrstuwxy1\&, +.Op Fl ABCFGHILPRSTUWZabcdfghiklmnopqrstuvwxy1\&, .Op Fl -color Ns = Ns Ar when .Op Fl D Ar format .Op Ar @@ -247,9 +244,11 @@ but only if .Dv stdout is a tty and either the .Fl G -flag is specified or the +flag is specified or one of the environment variables .Ev COLORTERM -environment variable is set and not empty. +or +.Ev CLICOLOR +is set and not empty. .Pp .Cm never will disable color regardless of environment variables. @@ -301,14 +300,9 @@ and .Fl s options. .It Fl g -This option has no effect. -It is only available for compatibility with -.Bx 4.3 , -where it was used to display the group name in the long +Display the long .Pq Fl l -format output. -This option is incompatible with -.St -p1003.1-2008 . +format output without the file owner's name or number. .It Fl h When used with the .Fl l @@ -399,6 +393,15 @@ of the file for sorting .Pq Fl t or printing .Pq Fl l . +.It Fl v +Sort following a natural ordering, using +.Xr strverscmp 3 +instead of +.Xr strcoll 3 +as the comparison function. +E.g., files lexicographically ordered +"bloem1", "bloem10", and "bloem9" would instead be ordered +"bloem1", "bloem9", and "bloem10", as one would perhaps expect. .It Fl w Force raw printing of non-printable characters. This is the default @@ -456,9 +459,9 @@ options all override each other; the last one specified determines the file time used. .Pp The -.Fl S +.Fl S , t and -.Fl t +.Fl v options override each other; the last one specified determines the sort order used. .Pp @@ -678,7 +681,7 @@ The default .Dq Li cons25 console has the proper capabilities, but to display the colors in an -.Xr xterm 1 , +.Xr xterm 1 Pq Pa ports/x11/xterm , for example, the .Ev TERM @@ -740,7 +743,7 @@ where is the foreground color and .Ar b is the background color. -When the background color is capitalized, the text will underlined. +When the background color is capitalized, the text is underlined. .Pp The color designators are as follows: .Pp @@ -881,10 +884,12 @@ specification. .Xr chmod 1 , .Xr getfacl 1 , .Xr sort 1 , -.Xr xterm 1 , +.Xr xterm 1 Pq Pa ports/x11/xterm , .Xr localeconv 3 , +.Xr strcoll 3 , .Xr strftime 3 , .Xr strmode 3 , +.Xr strverscmp 3 , .Xr termcap 5 , .Xr maclabel 7 , .Xr sticky 7 , @@ -902,7 +907,7 @@ utility conforms to and .St -p1003.1-2008 . The options -.Fl B , D , G , I , T , U , W , Z , b , h , w , y +.Fl B , D , G , I , T , U , W , Z , b , h , v , w , y and .Fl , are non-standard extensions. @@ -918,6 +923,11 @@ An .Nm command appeared in .At v1 . +.Pp +The +.Fl v +option was added in +.Fx 13.2 . .Sh BUGS To maintain backward compatibility, the relationships between the many options are quite complex. |