{"id":56921,"date":"2019-12-17T13:06:06","date_gmt":"2019-12-17T19:06:06","guid":{"rendered":"https:\/\/eshop.macsales.com\/blog\/?p=56921"},"modified":"2021-05-21T11:15:13","modified_gmt":"2021-05-21T16:15:13","slug":"moving-from-bash-to-zsh-terminal-changes-in-macos-catalina","status":"publish","type":"post","link":"https:\/\/eshop.macsales.com\/blog\/56921-moving-from-bash-to-zsh-terminal-changes-in-macos-catalina\/","title":{"rendered":"Moving From Bash to Zsh: Terminal Changes in macOS Catalina"},"content":{"rendered":"\n<div class=\"wp-block-image\"><figure class=\"alignright size-thumbnail\"><img loading=\"lazy\" decoding=\"async\" width=\"190\" height=\"168\" src=\"https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/TerminalIcon-568-190x168.png\" alt=\"macOS Terminal Icon\" class=\"wp-image-56954\" srcset=\"https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/TerminalIcon-568-190x168.png 190w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/TerminalIcon-568-136x120.png 136w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/TerminalIcon-568-284x252.png 284w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/TerminalIcon-568.png 568w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/TerminalIcon-568-190x168@2x.png 380w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/TerminalIcon-568-136x120@2x.png 272w\" sizes=\"auto, (max-width: 190px) 100vw, 190px\" \/><\/figure><\/div>\n\n\n\n<p>macOS Catalina has a number of new features and capabilities, but one change that\u2019s often overlooked is the new shell used in Terminal to interact with the Mac via the command line.&nbsp;<\/p>\n\n\n\n<p>The quick take away is Apple is moving from the Bash (Bourne Again Shell) to a newer Zsh. In this Rocket Yard guide, we\u2019ll look at how this change to Terminal and the command line affects you.<\/p>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"h-what-is-a-shell\">What is a Shell?<\/h2>\n\n\n\n<p>At the simplest level, a shell is a program that allows you to control a computer, in this case, a Mac, using commands you enter with the keyboard. Shells are usually interactive text-based interfaces that accept commands and present the results. There are a number of different shells you can use, but if you&#8217;re wondering why anyone would want to use a shell and a command line to control a computer, you need to take a trip back in time to the dawn of the computer age.<\/p>\n\n\n\n<p>In those early days, controlling a computer was a daunting task that could require you to manually load memory locations, one at a time, with the data that would eventually be run as a program. In some cases, this was done by setting a row of switches that represented a memory location address, and then loading data into the memory with another set of switches. This process was labor-intensive and prone to errors.<\/p>\n\n\n\n<p>In many cases, the manually loaded program was for a boot loader that allowed the computer to accept input from a paper tape reader.<\/p>\n\n\n\n<p>Once the paper tape reader was operational, you could load a shell program that allowed a Teletype to be used as a command line interface. Ah, those were the days.<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-full is-resized\"><a href=\"https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/IMSAI8080_1280.jpg\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/IMSAI8080_1280.jpg\" alt=\"IMSAI 808 personal computer.\" class=\"wp-image-56926\" width=\"640\" height=\"343\" srcset=\"https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/IMSAI8080_1280.jpg 1280w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/IMSAI8080_1280-224x120.jpg 224w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/IMSAI8080_1280-284x152.jpg 284w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/IMSAI8080_1280-190x102.jpg 190w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/IMSAI8080_1280-224x120@2x.jpg 448w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/IMSAI8080_1280-284x152@2x.jpg 568w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/IMSAI8080_1280-190x102@2x.jpg 380w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><\/a><figcaption>Early personal computers like the IMSAI 8080 used an array of switches to load programs manually &#8211; Image courtesy of Judson McCranie.<\/figcaption><\/figure><\/div>\n\n\n\n<p>Using a shell and a command line was a lot easier for working with a computer than rows and rows of toggle switches.<\/p>\n\n\n\n<p>OK, so the shell was a big improvement back then, but why is it still used today with modern computers?<\/p>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"h-the-shell-and-the-mac\">The Shell and the Mac<\/h2>\n\n\n\n<p>The Mac makes use of a UNIX-like operating system. And like most Unix or Linux based systems, the command line interface is one of the key methods for interacting with the operating system. The Mac (and many UNIX and Linux systems) also features a graphical user interface to make working with the computer even easier. But the command line still exists, and for working with core components of the operating system it can be very versatile, providing more capabilities than what is available in the GUI (Graphical User Interface).<\/p>\n\n\n\n<p>The shell controls how the command line is presented to the user and what features the command line supports. Most shells offer the following to some degree or other:<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li><strong>Shell Syntax<\/strong>: How the shell understands what you enter.<\/li><li><strong>Shell Commands<\/strong>: The actual commands the shell can execute.<\/li><li><strong>Shell Functions<\/strong>: The ability to group commands together.<\/li><li><strong>Shell Parameters<\/strong>: How and where the shell stores values.<\/li><li><strong>Shell Expansion<\/strong>: How parameters in a command are expanded<\/li><li><strong>Redirect<\/strong>: Controls the input and output of commands.<\/li><li><strong>Command Execution<\/strong>: What happens when commands are run.<\/li><li><strong>Shell Scripts<\/strong>: The ability to run a file containing multiple shell commands.<\/li><\/ul>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"h-why-is-apple-changing-the-shell\">Why is Apple Changing the Shell?<\/h2>\n\n\n\n<p>Apple is changing from the Bash shell to the Zsh (Z Shell). They haven\u2019t said specifically why the change is occurring, but we can make some educated guesses.<\/p>\n\n\n\n<p>Apple has been using the Bash shell since OS X Jaguar but hasn\u2019t updated Bash since version 3.2 was released in 2007. To put that in perspective, the version of Bash used on your Mac was new when the first iPhone was introduced.<\/p>\n\n\n\n<p>Apple is likely using the older version because the licensing for the Bash shell changed from GNU GPL 2 (General Public License) to GNU GPLv3, which includes restrictions that could cause problems for Apple.<\/p>\n\n\n\n<p>Apple muddled along with the older version for quite a few years, but really, it\u2019s time to move on to something more current.<\/p>\n\n\n\n<p>The Zsh included with macOS Catalina is version 5.7.1 and is the most current version at the time of Catalina&#8217;s release. It is also uses a less restrictive MIT license that is more to Apple&#8217;s liking.<\/p>\n\n\n\n<p class=\"footnote\"><strong>Note<\/strong>: Although Apple is changing to the Zsh in macOS Catalina, when running in Recovery Mode, the Bash shell is still used when you use the Terminal app.<\/p>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"h-am-i-forced-to-change-the-shell\">Am I Forced to Change the Shell?<\/h2>\n\n\n\n<p>Yes, and no. Apple will set the Zsh as the default for any new user account that is created in macOS Catalina or later. If you upgraded your Mac from an earlier version of the macOS, then those existing user accounts are still using the Bash shell.<\/p>\n\n\n\n<p>You are, however, free to upgrade all accounts to Zsh, or downgrade an account to Bash (or for that matter, to any shell you wish to use).<\/p>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"h-how-different-is-zsh\">How Different is Zsh?<\/h2>\n\n\n\n<p>Not very; Bash and Zsh have a very high level of compatibility between them. Both are based on the older Bourne shell. It\u2019s likely most Bash commands and scripts you may be using will run just fine under the Zsh.<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-full is-resized\"><a href=\"https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/AutoComplete1280.jpg\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/AutoComplete1280.jpg\" alt=\"Autocomplete shell terminal bash zsh on mac\" class=\"wp-image-56927\" width=\"640\" height=\"245\" srcset=\"https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/AutoComplete1280.jpg 1280w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/AutoComplete1280-284x109.jpg 284w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/AutoComplete1280-190x73.jpg 190w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/AutoComplete1280-284x109@2x.jpg 568w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/AutoComplete1280-190x73@2x.jpg 380w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><\/a><figcaption>Zsh supports auto-complete, type part of a command followed by hitting the tab key twice and a list of matches is displayed you can select from.<\/figcaption><\/figure><\/div>\n\n\n\n<p>The real advantage to the Zsh is the modern features it includes that make working with the shell very easy. This includes auto complete of command entries, and spell checking, a favorite of mine since I often make a typo in a command that Bash would just let go through and then chide me about there being no such command, while Zsh offers to make a correction to my command for me.<\/p>\n\n\n\n<p>For the fumble-fingered like me, that\u2019s reason enough to change to the Zsh.<\/p>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"h-what-about-all-my-bash-scripts\">What About All My Bash Scripts?<\/h2>\n\n\n\n<p>They should run fine; if you do come across a script with issues caused by the shell, you can either take the time to upgrade the script, or simply add a Shebang (#!) to force the script to use the Bash shell that is still included with the macOS:<\/p>\n\n\n\n<p>&nbsp;Add the following at the beginning of your Bash scripts to ensure compatibility:<\/p>\n\n\n\n<p><code>#!\/bin\/bash<\/code><\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-full is-resized\"><a href=\"https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/BashScript1280.jpg\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/BashScript1280.jpg\" alt=\"Bash script with first line Shebang.\" class=\"wp-image-56928\" width=\"640\" height=\"212\" srcset=\"https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/BashScript1280.jpg 1280w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/BashScript1280-284x94.jpg 284w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/BashScript1280-190x63.jpg 190w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/BashScript1280-284x94@2x.jpg 568w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/BashScript1280-190x63@2x.jpg 380w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><\/a><figcaption>Add the Shebang #!\/bin\/bash as the first line in your Bash scripts to ensure compatibility.<\/figcaption><\/figure><\/div>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"h-how-to-temporarily-change-shells\">How to Temporarily Change Shells<\/h2>\n\n\n\n<p>Zsh has been included with the macOS for quite a while; it just was never the default before. If you would like to temporarily try out the Zsh, do the following:<\/p>\n\n\n\n<p>Launch Terminal, located at \/Applications\/Utilities.<\/p>\n\n\n\n<p>At the Terminal command prompt, enter:<\/p>\n\n\n\n<p><code>zsh<\/code><\/p>\n\n\n\n<p>Hit enter or return.<\/p>\n\n\n\n<p>The shell being used in the current Terminal session will change to the Zsh and the command prompt will change to a percent sign (%).<\/p>\n\n\n\n<p>You can return to the bash shell by either quitting Terminal, or at the prompt enter:<\/p>\n\n\n\n<p><code>bash<\/code><\/p>\n\n\n\n<p>Hit enter or return.<\/p>\n\n\n\n<p class=\"footnote\">You can discover more about the Terminal app in the Rocket Yard guide: <a href=\"https:\/\/eshop.macsales.com\/blog\/39296-tech-101-introduction-to-the-macs-terminal-app-part-one\/\">Tech 101: Introduction to the Mac&#8217;s Terminal App, Part One<\/a><\/p>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"h-change-the-default-shell-to-use\">Change The Default Shell to Use<\/h2>\n\n\n\n<p>No matter which shell Apple sets for you as the default, you can change it with one of two methods:<\/p>\n\n\n\n<p>From the Terminal command line, enter:<\/p>\n\n\n\n<p><code>chsh -s \/bin\/zsh<\/code><\/p>\n\n\n\n<p>or<\/p>\n\n\n\n<p><code>chsh -s \/bin\/bash<\/code><\/p>\n\n\n\n<p>Depending on whether you wish to set Zsh or Bash as the default.<\/p>\n\n\n\n<p>Hit enter or return.<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-full is-resized\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/ChangeShell1280.jpg\" alt=\"Changing the sheel from bash to zsh in macos\" class=\"wp-image-56929\" width=\"640\" height=\"275\" srcset=\"https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/ChangeShell1280.jpg 1280w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/ChangeShell1280-280x120.jpg 280w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/ChangeShell1280-284x122.jpg 284w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/ChangeShell1280-190x81.jpg 190w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/ChangeShell1280-280x120@2x.jpg 560w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/ChangeShell1280-284x122@2x.jpg 568w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/ChangeShell1280-190x81@2x.jpg 380w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><figcaption>After changing the default shell you will need to open a new Terminal window to see the changes take affect.<\/figcaption><\/figure><\/div>\n\n\n\n<p><strong>You can also set the default shell using System Preferences:<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>Launch System Preferences, and select the Users &amp; Groups preference pane.<\/li><li>Click on the Lock icon in the bottom left corner, then supply your administrator password when requested.<\/li><li>Right-click on the user account in the sidebar whose default shell you wish to change. From the popup menu, select Advanced Options.<\/li><li>Locate the item labeled Login shell.<\/li><li>Use the dropdown menu to select one of the available shells.<\/li><\/ul>\n\n\n\n<p class=\"footnote\"><strong>Note<\/strong>: macOS Catalina does not include an entry in the dropdown menu for Bash. Instead, enter \/bin\/bash directly in the Login shell item.<\/p>\n\n\n\n<p>Click the OK button when ready.<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-full is-resized\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/ChangeShellSysPref1280.jpg\" alt=\"Change macOS shell in user preferences\" class=\"wp-image-56930\" width=\"640\" height=\"536\" srcset=\"https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/ChangeShellSysPref1280.jpg 1280w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/ChangeShellSysPref1280-143x120.jpg 143w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/ChangeShellSysPref1280-284x238.jpg 284w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/ChangeShellSysPref1280-190x159.jpg 190w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/ChangeShellSysPref1280-143x120@2x.jpg 286w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/ChangeShellSysPref1280-284x238@2x.jpg 568w, https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/ChangeShellSysPref1280-190x159@2x.jpg 380w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><figcaption>You can also change the default shell for each user from the Users &amp; Groups preference pane.<\/figcaption><\/figure><\/div>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"h-what-about-the-warning-message-to-change-to-zsh\">What About the Warning Message to Change to Zsh?<\/h2>\n\n\n\n<p>If you have Bash set as the default and you launch Terminal or open a new Terminal session, you will see the following message:<\/p>\n\n\n\n<p class=\"has-text-align-center\">&#8220;The default interactive shell is now zsh. To update your account to zsh, please run <code>chsh -s \/bin\/zsh<\/code>.&#8221;<\/p>\n\n\n\n<p>If you intend to keep using Bash you can remove this message by entering the following at the command prompt:<\/p>\n\n\n\n<p><code>export BASH_SILENCE_DEPRECATION_WARNING=1<\/code><\/p>\n\n\n\n<p>Hit enter or return.<\/p>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"h-shell-documentation\">Shell Documentation<\/h2>\n\n\n\n<p>It&#8217;s beyond the scope of this single article to tell you about the various capabilities of each shell. To do so would really require a book, or two. If you would like to discover more about the Bash and Zsh, you can check out the online documentation about each.<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li><a href=\"http:\/\/zsh.sourceforge.net\/\">Z Shell information<\/a><\/li><li><a href=\"https:\/\/www.gnu.org\/software\/bash\/\">Bash information<\/a><\/li><\/ul>\n\n\n\n<p>Do you use the Terminal app often? And if so, what shell do you prefer to use? Let us know in the comments below.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-text-color has-background has-vivid-cyan-blue-background-color has-vivid-cyan-blue-color is-style-wide\"\/>\n\n\n\n<ul class=\"wp-block-yoast-seo-related-links\"><li><a href=\"https:\/\/eshop.macsales.com\/blog\/39362-tech-101-introduction-to-the-macs-terminal-app-part-two\/\">Tech 101: Introduction to the Mac&#8217;s Terminal App, Part Two<\/a><\/li><li><a href=\"https:\/\/eshop.macsales.com\/blog\/39296-tech-101-introduction-to-the-macs-terminal-app-part-one\/\">Tech 101: Introduction to the Mac&#8217;s Terminal App, Part One<\/a><\/li><li><a href=\"https:\/\/eshop.macsales.com\/blog\/59087-bring-back-the-mac-startup-chime-with-this-terminal-command\/\">Bring Back the Mac Startup Chime With This Terminal Command<\/a><\/li><li><a href=\"https:\/\/eshop.macsales.com\/blog\/44540-want-simple-security-hide-secret-files-with-terminal\/\">Want Simple Security? Hide \u2018Secret\u2019 Files with Terminal<\/a><\/li><\/ul>\n\n\n\n<hr class=\"wp-block-separator has-text-color has-background has-vivid-cyan-blue-background-color has-vivid-cyan-blue-color is-style-wide\"\/>\n","protected":false},"excerpt":{"rendered":"<p>macOS Catalina has a number of new features and capabilities, but one change that\u2019s often overlooked is the new shell used in Terminal to interact with the Mac via the command line. <\/p>\n<p>The quick take away is Apple is moving from the Bash (Bourne Again Shell) to a newer Zsh. In this Rocket Yard guide we\u2019ll look at how this change to Terminal and the command line affects you.<\/p>\n","protected":false},"author":97,"featured_media":74883,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"spay_email":"","footnotes":""},"categories":[4],"class_list":["post-56921","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-tech-tips"],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v20.2 (Yoast SEO v20.2) - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Moving From Bash to Zsh: Terminal Changes in macOS Catalina<\/title>\n<meta name=\"description\" content=\"Zsh is the new default shell used in macOS Catalina and later. Find out how this impacts Terminal and your existing shell scripts.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/eshop.macsales.com\/blog\/56921-moving-from-bash-to-zsh-terminal-changes-in-macos-catalina\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Moving From Bash to Zsh: Terminal Changes in macOS Catalina\" \/>\n<meta property=\"og:description\" content=\"Zsh is the new default shell used in macOS Catalina and later. Find out how this impacts Terminal and your existing shell scripts.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/eshop.macsales.com\/blog\/56921-moving-from-bash-to-zsh-terminal-changes-in-macos-catalina\/\" \/>\n<meta property=\"og:site_name\" content=\"Rocket Yard\" \/>\n<meta property=\"article:published_time\" content=\"2019-12-17T19:06:06+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2021-05-21T16:15:13+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/BashToZsh-1400x788-1.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"1400\" \/>\n\t<meta property=\"og:image:height\" content=\"788\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"Tom Nelson\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Tom Nelson\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"9 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/eshop.macsales.com\/blog\/56921-moving-from-bash-to-zsh-terminal-changes-in-macos-catalina\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/eshop.macsales.com\/blog\/56921-moving-from-bash-to-zsh-terminal-changes-in-macos-catalina\/\"},\"author\":{\"name\":\"Tom Nelson\",\"@id\":\"https:\/\/eshop.macsales.com\/blog\/#\/schema\/person\/647f465acd469444183711d2a22648cb\"},\"headline\":\"Moving From Bash to Zsh: Terminal Changes in macOS Catalina\",\"datePublished\":\"2019-12-17T19:06:06+00:00\",\"dateModified\":\"2021-05-21T16:15:13+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/eshop.macsales.com\/blog\/56921-moving-from-bash-to-zsh-terminal-changes-in-macos-catalina\/\"},\"wordCount\":1585,\"commentCount\":27,\"publisher\":{\"@id\":\"https:\/\/eshop.macsales.com\/blog\/#organization\"},\"keywords\":[\"Bash\",\"Scripts\",\"Shell\",\"Terminal\",\"Zsh\"],\"articleSection\":[\"Tech Tips\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/eshop.macsales.com\/blog\/56921-moving-from-bash-to-zsh-terminal-changes-in-macos-catalina\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/eshop.macsales.com\/blog\/56921-moving-from-bash-to-zsh-terminal-changes-in-macos-catalina\/\",\"url\":\"https:\/\/eshop.macsales.com\/blog\/56921-moving-from-bash-to-zsh-terminal-changes-in-macos-catalina\/\",\"name\":\"Moving From Bash to Zsh: Terminal Changes in macOS Catalina\",\"isPartOf\":{\"@id\":\"https:\/\/eshop.macsales.com\/blog\/#website\"},\"datePublished\":\"2019-12-17T19:06:06+00:00\",\"dateModified\":\"2021-05-21T16:15:13+00:00\",\"description\":\"Zsh is the new default shell used in macOS Catalina and later. Find out how this impacts Terminal and your existing shell scripts.\",\"breadcrumb\":{\"@id\":\"https:\/\/eshop.macsales.com\/blog\/56921-moving-from-bash-to-zsh-terminal-changes-in-macos-catalina\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/eshop.macsales.com\/blog\/56921-moving-from-bash-to-zsh-terminal-changes-in-macos-catalina\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/eshop.macsales.com\/blog\/56921-moving-from-bash-to-zsh-terminal-changes-in-macos-catalina\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/eshop.macsales.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Moving From Bash to Zsh: Terminal Changes in macOS Catalina\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/eshop.macsales.com\/blog\/#website\",\"url\":\"https:\/\/eshop.macsales.com\/blog\/\",\"name\":\"Rocket Yard\",\"description\":\"Your source for expert tips, special deals, commentary, reviews, and the latest tech news.\",\"publisher\":{\"@id\":\"https:\/\/eshop.macsales.com\/blog\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/eshop.macsales.com\/blog\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/eshop.macsales.com\/blog\/#organization\",\"name\":\"OWC\",\"url\":\"https:\/\/eshop.macsales.com\/blog\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/eshop.macsales.com\/blog\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2020\/06\/rocket-yard-logo-round.png\",\"contentUrl\":\"https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2020\/06\/rocket-yard-logo-round.png\",\"width\":1024,\"height\":1024,\"caption\":\"OWC\"},\"image\":{\"@id\":\"https:\/\/eshop.macsales.com\/blog\/#\/schema\/logo\/image\/\"}},{\"@type\":\"Person\",\"@id\":\"https:\/\/eshop.macsales.com\/blog\/#\/schema\/person\/647f465acd469444183711d2a22648cb\",\"name\":\"Tom Nelson\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/eshop.macsales.com\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/cb537829ec9582eb81bd2dcf5c7e88d981ed66bd6f65dd36508faf46d38ba5a9?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/cb537829ec9582eb81bd2dcf5c7e88d981ed66bd6f65dd36508faf46d38ba5a9?s=96&d=mm&r=g\",\"caption\":\"Tom Nelson\"},\"description\":\"Tom has been an enthusiastic Mac user since the Mac Plus. He\u2019s also been known to dabble in the dark side, otherwise known as Windows, and has a well-deserved reputation for being able to explain almost anything to anybody. Tom\u2019s background includes more than 30 years as an engineer, programmer, network manager, software tester, software reviewer, database designer, and computer network and systems designer. His online experience includes working as a sysop, forum leader, writer, and software library manager.\",\"sameAs\":[\"http:\/\/rocketyard.com\"],\"url\":\"https:\/\/eshop.macsales.com\/blog\/author\/tom-n\/\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"Moving From Bash to Zsh: Terminal Changes in macOS Catalina","description":"Zsh is the new default shell used in macOS Catalina and later. Find out how this impacts Terminal and your existing shell scripts.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/eshop.macsales.com\/blog\/56921-moving-from-bash-to-zsh-terminal-changes-in-macos-catalina\/","og_locale":"en_US","og_type":"article","og_title":"Moving From Bash to Zsh: Terminal Changes in macOS Catalina","og_description":"Zsh is the new default shell used in macOS Catalina and later. Find out how this impacts Terminal and your existing shell scripts.","og_url":"https:\/\/eshop.macsales.com\/blog\/56921-moving-from-bash-to-zsh-terminal-changes-in-macos-catalina\/","og_site_name":"Rocket Yard","article_published_time":"2019-12-17T19:06:06+00:00","article_modified_time":"2021-05-21T16:15:13+00:00","og_image":[{"width":1400,"height":788,"url":"https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/BashToZsh-1400x788-1.jpg","type":"image\/jpeg"}],"author":"Tom Nelson","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Tom Nelson","Est. reading time":"9 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/eshop.macsales.com\/blog\/56921-moving-from-bash-to-zsh-terminal-changes-in-macos-catalina\/#article","isPartOf":{"@id":"https:\/\/eshop.macsales.com\/blog\/56921-moving-from-bash-to-zsh-terminal-changes-in-macos-catalina\/"},"author":{"name":"Tom Nelson","@id":"https:\/\/eshop.macsales.com\/blog\/#\/schema\/person\/647f465acd469444183711d2a22648cb"},"headline":"Moving From Bash to Zsh: Terminal Changes in macOS Catalina","datePublished":"2019-12-17T19:06:06+00:00","dateModified":"2021-05-21T16:15:13+00:00","mainEntityOfPage":{"@id":"https:\/\/eshop.macsales.com\/blog\/56921-moving-from-bash-to-zsh-terminal-changes-in-macos-catalina\/"},"wordCount":1585,"commentCount":27,"publisher":{"@id":"https:\/\/eshop.macsales.com\/blog\/#organization"},"keywords":["Bash","Scripts","Shell","Terminal","Zsh"],"articleSection":["Tech Tips"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/eshop.macsales.com\/blog\/56921-moving-from-bash-to-zsh-terminal-changes-in-macos-catalina\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/eshop.macsales.com\/blog\/56921-moving-from-bash-to-zsh-terminal-changes-in-macos-catalina\/","url":"https:\/\/eshop.macsales.com\/blog\/56921-moving-from-bash-to-zsh-terminal-changes-in-macos-catalina\/","name":"Moving From Bash to Zsh: Terminal Changes in macOS Catalina","isPartOf":{"@id":"https:\/\/eshop.macsales.com\/blog\/#website"},"datePublished":"2019-12-17T19:06:06+00:00","dateModified":"2021-05-21T16:15:13+00:00","description":"Zsh is the new default shell used in macOS Catalina and later. Find out how this impacts Terminal and your existing shell scripts.","breadcrumb":{"@id":"https:\/\/eshop.macsales.com\/blog\/56921-moving-from-bash-to-zsh-terminal-changes-in-macos-catalina\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/eshop.macsales.com\/blog\/56921-moving-from-bash-to-zsh-terminal-changes-in-macos-catalina\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/eshop.macsales.com\/blog\/56921-moving-from-bash-to-zsh-terminal-changes-in-macos-catalina\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/eshop.macsales.com\/blog\/"},{"@type":"ListItem","position":2,"name":"Moving From Bash to Zsh: Terminal Changes in macOS Catalina"}]},{"@type":"WebSite","@id":"https:\/\/eshop.macsales.com\/blog\/#website","url":"https:\/\/eshop.macsales.com\/blog\/","name":"Rocket Yard","description":"Your source for expert tips, special deals, commentary, reviews, and the latest tech news.","publisher":{"@id":"https:\/\/eshop.macsales.com\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/eshop.macsales.com\/blog\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/eshop.macsales.com\/blog\/#organization","name":"OWC","url":"https:\/\/eshop.macsales.com\/blog\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/eshop.macsales.com\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2020\/06\/rocket-yard-logo-round.png","contentUrl":"https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2020\/06\/rocket-yard-logo-round.png","width":1024,"height":1024,"caption":"OWC"},"image":{"@id":"https:\/\/eshop.macsales.com\/blog\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":"https:\/\/eshop.macsales.com\/blog\/#\/schema\/person\/647f465acd469444183711d2a22648cb","name":"Tom Nelson","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/eshop.macsales.com\/blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/cb537829ec9582eb81bd2dcf5c7e88d981ed66bd6f65dd36508faf46d38ba5a9?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/cb537829ec9582eb81bd2dcf5c7e88d981ed66bd6f65dd36508faf46d38ba5a9?s=96&d=mm&r=g","caption":"Tom Nelson"},"description":"Tom has been an enthusiastic Mac user since the Mac Plus. He\u2019s also been known to dabble in the dark side, otherwise known as Windows, and has a well-deserved reputation for being able to explain almost anything to anybody. Tom\u2019s background includes more than 30 years as an engineer, programmer, network manager, software tester, software reviewer, database designer, and computer network and systems designer. His online experience includes working as a sysop, forum leader, writer, and software library manager.","sameAs":["http:\/\/rocketyard.com"],"url":"https:\/\/eshop.macsales.com\/blog\/author\/tom-n\/"}]}},"jetpack_featured_media_url":"https:\/\/eshop.macsales.com\/blog\/wp-content\/uploads\/2019\/12\/BashToZsh-1400x788-1.jpg","jetpack_shortlink":"https:\/\/wp.me\/pmPaT-eO5","_links":{"self":[{"href":"https:\/\/eshop.macsales.com\/blog\/wp-json\/wp\/v2\/posts\/56921","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/eshop.macsales.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/eshop.macsales.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/eshop.macsales.com\/blog\/wp-json\/wp\/v2\/users\/97"}],"replies":[{"embeddable":true,"href":"https:\/\/eshop.macsales.com\/blog\/wp-json\/wp\/v2\/comments?post=56921"}],"version-history":[{"count":9,"href":"https:\/\/eshop.macsales.com\/blog\/wp-json\/wp\/v2\/posts\/56921\/revisions"}],"predecessor-version":[{"id":74884,"href":"https:\/\/eshop.macsales.com\/blog\/wp-json\/wp\/v2\/posts\/56921\/revisions\/74884"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/eshop.macsales.com\/blog\/wp-json\/wp\/v2\/media\/74883"}],"wp:attachment":[{"href":"https:\/\/eshop.macsales.com\/blog\/wp-json\/wp\/v2\/media?parent=56921"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/eshop.macsales.com\/blog\/wp-json\/wp\/v2\/categories?post=56921"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}