{"id":2406,"date":"2020-07-26T11:43:31","date_gmt":"2020-07-26T16:43:31","guid":{"rendered":"https:\/\/bitpost.com\/news\/?p=2406"},"modified":"2020-12-21T23:18:42","modified_gmt":"2020-12-22T04:18:42","slug":"run-from-bash-like-your-career-depends-on-it","status":"publish","type":"post","link":"https:\/\/bitpost.com\/news\/2020\/run-from-bash-like-your-career-depends-on-it\/","title":{"rendered":"Run from bash like your career depends on it"},"content":{"rendered":"\n<p>Bash is the worst pile of anti-patterns and hacked up bullshit, but what would you expect from something that&#8217;s been our emergency-room band-aid for as long as we&#8217;ve been alive?  This is just a reminder, for your career&#8217;s sake, to NOT make it one of your &#8220;specialty languages&#8221;.  Learn what you have to.  And double down on a modern, sane scripting language.  I&#8217;ve tooled up node to do all things command-line, I recommend you do the same &#8211; but even writing little Java or C++ command-line apps is better than letting bash poison your brain!  Just say no.  And some day, our great-great-grandchildren will have a replacement.  No, not another sh variant.  A true sane modern programming language.  okbyeeee!<\/p>\n\n\n\n<p>Hate of the day:  I love how [rm -f ] &#8220;fails&#8221; (non-zero error code) but [mkdir -p &#8230;] &#8220;succeeds&#8221;, and there is no [mv -f &#8230;].  The Unix philosophy: do one thing, and do it well, but always slightly differently than anyone else would have done it.  Sure it&#8217;s bizarre bazaar chaos, but it&#8217;s &#8220;beautiful&#8221;.  Ummmm&#8230;. no, fuck you, I don&#8217;t want to memorize your chaos.<\/p>\n\n\n\n<p><strong>UPDATE<\/strong>: Dude.  In my defense I was in pain and jacked on meds when I wrote this, haha.  Step away from the oxy, take less Adderall&#8230; calm ye self down.  &#8220;Whatever Works&#8221;.<\/p>\n\n\n\n<p><strong>UPDATE 2:<\/strong> Yeah, the horror is real.  <a href=\"https:\/\/unix.stackexchange.com\/a\/33340\/66489\">Yet another damning example<\/a> of why, for your career&#8217;s sake, you should focus on a real scripting language and not (ba)sh&#8217;s arbitrary stupidity.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Bash is the worst pile of anti-patterns and hacked up bullshit, but what would you expect from something that&#8217;s been our emergency-room band-aid for as long as we&#8217;ve been alive? This is just a reminder, for your career&#8217;s sake, to NOT make it one of your &#8220;specialty languages&#8221;. Learn what you have to. And double [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"enabled":false},"version":2}},"categories":[22,216,19,2],"tags":[244,257],"class_list":["post-2406","post","type-post","status-publish","format-standard","hentry","category-cpp","category-node-js","category-opensource","category-chatter","tag-bash","tag-patterns"],"aioseo_notices":[],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/p9M11L-CO","jetpack_likes_enabled":true,"_links":{"self":[{"href":"https:\/\/bitpost.com\/news\/wp-json\/wp\/v2\/posts\/2406","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/bitpost.com\/news\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/bitpost.com\/news\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/bitpost.com\/news\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/bitpost.com\/news\/wp-json\/wp\/v2\/comments?post=2406"}],"version-history":[{"count":6,"href":"https:\/\/bitpost.com\/news\/wp-json\/wp\/v2\/posts\/2406\/revisions"}],"predecessor-version":[{"id":2433,"href":"https:\/\/bitpost.com\/news\/wp-json\/wp\/v2\/posts\/2406\/revisions\/2433"}],"wp:attachment":[{"href":"https:\/\/bitpost.com\/news\/wp-json\/wp\/v2\/media?parent=2406"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/bitpost.com\/news\/wp-json\/wp\/v2\/categories?post=2406"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/bitpost.com\/news\/wp-json\/wp\/v2\/tags?post=2406"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}