Skip to content

Comment on Ask HN: How many have learned a language they hated just to get a job? parent

Comments

> UNIX ideology taken to the logical extreme

I thought "UNIX ideology" was "streams in motion; streams at rest." (Everything reads streams and produces streams; you create complex programs by piping a stream through smaller programs.) Shell scripting is really the pinnacle of UNIXism.

I was thinking "there's more than one way to do it". Perl can also handle streams very efficiently and do lots more. Having worked in the operations world, I also find shell scripting to be an anti-pattern. Automation/tools built as shell scripts are much more brittle and harder to make _production_ ready (i.e., running 24/7 in a datacenter with no human intervention, but being held up to a strict SLA).

Perl (as well as Ruby and to a lesser extent Python) lets you scale from simple scripts to full-on tools. It's easy to write pipes, filters, one-liners and simple scripts in Perl. You can then add logging to them (using the excellent log4perl package), let them make socket calls to a monitoring system (or embed a server in them to let a monitoring system connect to them), debug them with a real debugger, extend them to call C libraries (xs is easy) and package them into classes and packages, allowing others to re-use them as components of other systems.

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.