tmutil compare gives differences between two backups. But I wonder how do I sort the output by file size? With GNU
sort, there is the
--human-numeric-sort option for this, but the
sort which is part of macOS doesn't support this. So how can I sort the result by file size?
I don't know exactly how
sort -h is supposed to work since it mixes the
G prefixes, but it was at least workable for me in Mojave:
cat tmutil-compare | grep "M " | cut -c 3- | sort -h