4 ms·
> That includes run-once scripts (where you might have used Perl in the past) I never learned perl, but nearly every time I try to do something complex in bash
by 6gvONxR4sf7o 6y ago
> That includes run-once scripts (where you might have used Perl in the past)
I never learned perl, but nearly every time I try to do something complex in bash (more than a dozen lines or so containing control flow) I regret it and end up rewriting it in python. Then the next time comes around and I go "I really should get better at shell scripting, I'll do that," and bash my head against the wall for a while then end up going back to python again.
- lioeters 6y ago> bash my head against the wall for a while I'm similar with shell scripts - awkward at best. The longest one I've written is only a few hundred lines, but it was tough to write and test. It sits in the middle of a busy build pipeline, and while it does the job, I'm wary of making any changes. For long-term maintenance, especially for other people that may need to keep it runnning, I'd trade some performance for a higher-level language like Python or JavaScript - the code and logic would be so much simpler.