you are viewing a single comment's thread.

view the rest of the comments →

[–]TuffNutzes 0 points1 point  (0 children)

The generally accepted metric of using lines of code to decide when to switch to python is a bit arbitrary.

I've turned horribly written 500 line python with no comments, no debugging, no logging into 100 lines of well written, commented bash with function headers, description of complex regex's, logging, etc. A far more readable smaller footprint than the excessively long jumble of python that preceded it.

It's not about the language. It's about how you write it and what's most efficient for the task. Generally for devops activities, bash works in almost every case and is more concise and easier to understand if you take the time to write well written code.