3 ms·
-p is immensely useful. Of course it's redundant in long format; it's for using in short format. -r is also very useful (I use -tr all the time, which I can't
by lmm 15y ago
-p is immensely useful. Of course it's redundant in long format; it's for using in short format.
-r is also very useful (I use -tr all the time, which I can't immediately see how I'd replace with sort), and while I could replace ls -lS with piping into sort, you seem to be assuming ls will always be outputting one file per line, which is far from its most useful output mode when running it in a terminal.
- masklinn 15y ago> you seem to be assuming ls will always be outputting one file per line No, I am assuming a "do one thing" `ls` would be used in long format (or as inode numbers) whenever it need to be worked with, and would be massaged into form by further commands. For `t`, `r`, `S` and a bunch of others you'd ls, sort and then cut/awk/whatever to format into a "short form". Not that it matters a bit. Also, I didn't claim these weren't useful, I claimed they were redundant. Which they are.