<feed xmlns='http://www.w3.org/2005/Atom'>
<title>src/bin/ls, branch main</title>
<subtitle>FreeBSD source tree</subtitle>
<id>https://cgit-dev.freebsd.org/src/atom?h=main</id>
<link rel='self' href='https://cgit-dev.freebsd.org/src/atom?h=main'/>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/'/>
<updated>2026-02-11T19:56:37Z</updated>
<entry>
<title>ls: check fts_children() for errors that may not surface otherwise</title>
<updated>2026-02-11T19:56:37Z</updated>
<author>
<name>Kyle Evans</name>
<email>kevans@FreeBSD.org</email>
</author>
<published>2026-02-11T19:55:55Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=7bf81e39d83087dc7f984077b5eed5a48df794d4'/>
<id>urn:sha1:7bf81e39d83087dc7f984077b5eed5a48df794d4</id>
<content type='text'>
In particular, if one simply does a non-recursive `ls` on a directory
that is not accessible, there are some classes of errors that may cause
it to fail that wouldn't be surfaced unless we do an fts_read() that
will recurse into the inaccessible directory.  Catch those kinds of
errors here since we cannot expect to an FTS_ERR/FTS_DNR entry to follow
up on them.

PR:		287451
Reviewed by:	kib
Discusssed with:	des
Differential Revision:	https://reviews.freebsd.org/D51056
</content>
</entry>
<entry>
<title>ls: --group-directories requires stat information</title>
<updated>2025-01-22T07:29:29Z</updated>
<author>
<name>Piotr Pawel Stefaniak</name>
<email>pstef@FreeBSD.org</email>
</author>
<published>2025-01-21T22:47:30Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=6ba2f08cea8cd5c801b78eb8842f7f96bf2d255c'/>
<id>urn:sha1:6ba2f08cea8cd5c801b78eb8842f7f96bf2d255c</id>
<content type='text'>
Fixes:	8b92977857f8
</content>
</entry>
<entry>
<title>ls.1: bump date after 82fa7f83b53b and 8b92977857f8</title>
<updated>2025-01-16T16:05:43Z</updated>
<author>
<name>Piotr Pawel Stefaniak</name>
<email>pstef@FreeBSD.org</email>
</author>
<published>2025-01-16T16:05:43Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=4ed2448a4f2b32d0c4055c282e4cc2b691d621ed'/>
<id>urn:sha1:4ed2448a4f2b32d0c4055c282e4cc2b691d621ed</id>
<content type='text'>
</content>
</entry>
<entry>
<title>ls: implement --group-directories-first for compatibility with GNU ls</title>
<updated>2025-01-16T16:00:17Z</updated>
<author>
<name>Piotr Pawel Stefaniak</name>
<email>pstef@FreeBSD.org</email>
</author>
<published>2025-01-06T21:26:14Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=8b92977857f8acaa539c21800b024edea9eee8b4'/>
<id>urn:sha1:8b92977857f8acaa539c21800b024edea9eee8b4</id>
<content type='text'>
Also implement --group-directories which takes a parameter.
"first" is equivalent to --group-directories-first, "last" gives
reversed sorting.

Changes in sorting between elements of the same type (files,
directories) are not intended.

Differential Revision:	https://reviews.freebsd.org/D48347
</content>
</entry>
<entry>
<title>ls -lh: humanize the total</title>
<updated>2025-01-16T16:00:17Z</updated>
<author>
<name>Piotr Pawel Stefaniak</name>
<email>pstef@FreeBSD.org</email>
</author>
<published>2025-01-06T17:59:03Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=82fa7f83b53b3c5b7f3a5c5560edc7caeeaa1029'/>
<id>urn:sha1:82fa7f83b53b3c5b7f3a5c5560edc7caeeaa1029</id>
<content type='text'>
Before this change, the total printed on the first line was always in
blocks.

Now the long format with -h will print the "humanized number" instead.

`ls -sh` never provided sizes in anything other than blocks, total or
individual, and this commit doesn't change that.

The total number of blocks is a sum of fts_statp-&gt;st_blocks, so it's
multiplied by 512 and not by blocksize.

$ ls -lh /usr/bin | head -n 2
total 442 MB
-r-xr-xr-x 1 root wheel 70B Dec 20 21:06 CC

Differential Revision:	https://reviews.freebsd.org/D48329
</content>
</entry>
<entry>
<title>ls: Release resources before returning from traverse()</title>
<updated>2025-01-14T14:20:26Z</updated>
<author>
<name>Mark Johnston</name>
<email>markj@FreeBSD.org</email>
</author>
<published>2025-01-14T14:20:26Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=e6c9c463384d11a44af3e5f2cc947fb69f3a1968'/>
<id>urn:sha1:e6c9c463384d11a44af3e5f2cc947fb69f3a1968</id>
<content type='text'>
PR:		278476
MFC after:	2 weeks
Reported by:	valgrind
</content>
</entry>
<entry>
<title>ls: Make -, apply to -s as well as -l.</title>
<updated>2024-07-24T20:07:06Z</updated>
<author>
<name>Dag-Erling Smørgrav</name>
<email>des@FreeBSD.org</email>
</author>
<published>2024-07-24T20:06:39Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=647d4a8cafd2c9b291cab388191bc7fcfe12a66b'/>
<id>urn:sha1:647d4a8cafd2c9b291cab388191bc7fcfe12a66b</id>
<content type='text'>
While here, remove a bogus comment about a gcc bug.  The bug was in ls,
which used an incorrect format string, and in libc, which accepted it.

MFC after:	1 week
Reviewed by:	brooks
Differential Revision:	https://reviews.freebsd.org/D46067
</content>
</entry>
<entry>
<title>Remove residual blank line at start of Makefile</title>
<updated>2024-07-15T22:43:39Z</updated>
<author>
<name>Warner Losh</name>
<email>imp@FreeBSD.org</email>
</author>
<published>2024-07-15T04:46:32Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=e9ac41698b2f322d55ccf9da50a3596edb2c1800'/>
<id>urn:sha1:e9ac41698b2f322d55ccf9da50a3596edb2c1800</id>
<content type='text'>
This is a residual of the $FreeBSD$ removal.

MFC After: 3 days (though I'll just run the command on the branches)
Sponsored by: Netflix
</content>
</entry>
<entry>
<title>ls.1: Mention CLICOLOR environment variable</title>
<updated>2024-02-21T10:54:58Z</updated>
<author>
<name>Gordon Bergling</name>
<email>gbe@FreeBSD.org</email>
</author>
<published>2024-02-21T10:54:58Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=ffea732c5192070a6877409428b0a2cc1728aa16'/>
<id>urn:sha1:ffea732c5192070a6877409428b0a2cc1728aa16</id>
<content type='text'>
Mention CLICOLOR environment variable in the manual page.

PR:	276556
Submitted by:	bsdcode at disroot dot org
Reviewed by:	imp
MFC after:	3 days
Differential Revision:	https://reviews.freebsd.org/D43970
</content>
</entry>
<entry>
<title>ls: Fix -v and associated test</title>
<updated>2024-02-19T16:50:04Z</updated>
<author>
<name>Warner Losh</name>
<email>imp@FreeBSD.org</email>
</author>
<published>2024-02-19T16:48:05Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=ef75877fc2d93199aab2b509089136c433af1f20'/>
<id>urn:sha1:ef75877fc2d93199aab2b509089136c433af1f20</id>
<content type='text'>
The cleanup of d854370fa86b7 had a cut and paste error (so f_verssort
was set to 1 and then to 0 rather thame f_timesort being set to 0).

Fixes: d854370fa86b7
Sponsored by: Netflix
</content>
</entry>
</feed>
