this post was submitted on 11 Jan 2026
337 points (93.5% liked)

Programmer Humor

28379 readers
1231 users here now

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

founded 2 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
[โ€“] palordrolap@fedia.io 21 points 16 hours ago (1 children)

history | grep -E '(sed|grep|awk|perl)' | wc -l 107

Dang. That's out of 1000. I need to up my game. Also three of those seds are part of something with a -basedir and don't count.

So yeah, about 10% of my commands are iterating shell pipe things for poops and giggles, I guess.

... and this got me going down the rabbit hole of writing a filter for my history to pull out the first command on the line. This is non-trivial because of potential preceding variable assignments. Most used commands are currently apt and man and ls. I think apt is a Spiders Georg situation because the system is fairly fresh and I keep finding things that I haven't installed yet. Also I went through a patch of trying to parse its output.

... oh, er... unga bunga.

$ history | grep -E '(sed|grep|awk|perl)' | wc -l
50
$ history | wc -l
500

Checks out perfectly.