How to create a simple random name selector in the Linux terminal

Опубликовано: 14 Октябрь 2024
на канале: PaBlo Tech
30
0

Everyday the same problem at the office, who's gonna place the #lunch order today? The #linux "shuf" command is a perfect solution for that question. Simply combine it with "head" and you'll get a simple #random selector.

$~ shuf -e "bob" "steve" "jim" | head -n 1