Hacker News new | ask | show | jobs
by oefrha 726 days ago
Shelling out to `ls` (exec + opendir + readdir + stat + pipe IO) is not faster than opendir + readdir + stat. `ls --dired` is definitely not portable. readdir and stat (the libc functions) are portable, work across POSIX and other Unix-likes. And the customization point here doesn’t provide any benefit for the user, it serves to let the user shoulder the responsibility for its own design defect (has to guess whether the `ls` supports --dired or not).