I've been learning stuff about bash
rapidly in the last several years, including better and faster ways of accomplishing common tasks. Here are some of my favorites.
Random n lines of a file
Antipattern
ls | shuf | head -n1
Improvement
ls | shuf -n1
I learned this week that the venerable shuf …