{"id":1893,"date":"2016-03-31T19:05:21","date_gmt":"2016-03-31T09:05:21","guid":{"rendered":"http:\/\/www.somethinkodd.com\/oddthinking\/?p=1893"},"modified":"2016-03-31T19:05:21","modified_gmt":"2016-03-31T09:05:21","slug":"bashing-bash","status":"publish","type":"post","link":"https:\/\/www.somethinkodd.com\/oddthinking\/2016\/03\/31\/bashing-bash\/","title":{"rendered":"Bashing bash"},"content":{"rendered":"<p>Today, Twitter was awash with people talking about Linux on Windows.<\/p>\n<p>It took a few hours before I got around to finding out what they were talking about. <a href=\"http:\/\/techcrunch.com\/2016\/03\/30\/be-very-afraid-hell-has-frozen-over-bash-is-coming-to-windows-10\/\">Microsoft is bringing the Bash shell to Windows 10<\/a>:<\/p>\n<blockquote><p>Here is an announcement from Microsoft Build you probably didn\u00e2\u20ac\u2122t see coming: Microsoft today announced that it is bringing the GNU project\u00e2\u20ac\u2122s Bash shell to Windows. Bash (Bourne Again SHell) has long been a standard on OS X and many Linux distribution systems, while the default terminal for developers on Windows is Microsoft\u00e2\u20ac\u2122s own PowerShell.<\/p>\n<p>More importantly than bringing the shell over to Windows, developers will now be able to write their .sh Bash scripts on Windows, as well (or use Emacs to edit their code). Microsoft noted that this will work through a new Linux subsystem in Windows 10 that Microsoft worked on with Canonical.<\/p><\/blockquote>\n<p>Let&#8217;s put aside that Emacs has been running on Windows for decades (okay, I can only <a href=\"https:\/\/www.emacswiki.org\/emacs?action=rc;all=1;from=1;showedit=1;rcidonly=MsWindowsInstallation\">prove it back to 2007<\/a>, but I am sure I used it &#8211; and discarded it as silly idea &#8211; earlier), and that I have often written bash commands in Windows, even if I run them on Linux.<\/p>\n<p>I am still having trouble caring about this announcement. Every time I try to write a bash (or batch file or Powershell) script longer than about five lines, I realise my mistake and rewrite it in Python, where it is cleaner, safer and more portable. (If you want to replace &#8220;Python&#8221; with &#8220;Ruby&#8221; or your favourite modern scripting language, that&#8217;s fine too. I am not defending Python here, I am bashing bash.)<\/p>\n<p>Microsoft may as well tell me that they are going to support those old Sun mice that required the special gridded mouse mats. Why would we want to go back to that?<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Microsoft are porting bash to Windows. Microsoft may as well tell me that they are going to support those old Sun mice that required the special gridded mouse mats. Why would we want to go back to that?<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_s2mail":"yes","footnotes":""},"categories":[25,34],"tags":[],"class_list":["post-1893","post","type-post","status-publish","format-standard","hentry","category-insufficiently-advanced-technology","category-software-development"],"_links":{"self":[{"href":"https:\/\/www.somethinkodd.com\/oddthinking\/wp-json\/wp\/v2\/posts\/1893","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.somethinkodd.com\/oddthinking\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.somethinkodd.com\/oddthinking\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.somethinkodd.com\/oddthinking\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.somethinkodd.com\/oddthinking\/wp-json\/wp\/v2\/comments?post=1893"}],"version-history":[{"count":3,"href":"https:\/\/www.somethinkodd.com\/oddthinking\/wp-json\/wp\/v2\/posts\/1893\/revisions"}],"predecessor-version":[{"id":1896,"href":"https:\/\/www.somethinkodd.com\/oddthinking\/wp-json\/wp\/v2\/posts\/1893\/revisions\/1896"}],"wp:attachment":[{"href":"https:\/\/www.somethinkodd.com\/oddthinking\/wp-json\/wp\/v2\/media?parent=1893"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.somethinkodd.com\/oddthinking\/wp-json\/wp\/v2\/categories?post=1893"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.somethinkodd.com\/oddthinking\/wp-json\/wp\/v2\/tags?post=1893"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}