Bash shell in Windows 10

I recently became aware of a new capability in Windows 10. It does give me a reason to use that operating system again (at least from time to time). With the Windows 10 Anniversary update, one can now run the Bash shell directly on Windows. Looks like this only applies to Windows 10, but it is a definite enhancement. After you install all the necessary steps, you will see the following added to your start menu applications [Bash on Ubuntu on Windows].

 

Bash shell on Ubuntu on Windows

This means we are closer to not having to do all sorts of contortions (such as using PuTTY and Cygwin). Let’s see what we need to do to configure Windows 10 for this capability.

First, make certain you have the Windows 10 Anniversary update installed. If not, you will need to do so. Note the screen capture below. This update is feature update version 1607. You will need to restart your computer once the update has been installed.

Windows Anniversary update

 

Next, open settings, and configure your environment for “developer mode.” You will find this under “Settings > Update and Security.”

 

Configuring developer mode in Windows 10

 

It will take some time to install the necessary components (and you will once again need to restart your computer).

Once you have restarted, go into Settings again and search for “Windows Features.” Frankly, I am not a fan of all the new names and locations (apps instead of programs and so forth). Guess that is why I just find it easier to search for a given setting. I have highlighted the feature you need to select below. You want to scroll down and find Windows Subsystem for Linux (Beta). Once you click “ok,” it will take a little while to install all the features. And… guess what… you need to restart your computer again.

 

Add remove Windows features

You can then search for Bash among the apps. This will open the following screen (and you will need to create a username and password to use this environment). Don’t forget your password as you will need that every time you install a package or perform any sort of sudo command. When you open Bash for the first time, you see the following:

 

Installing Bash for the first time

 

Once the install has finished, you will see the application in your start menu (as shown at the beginning of this post). You can then install node, npm, and all sorts of useful items. One example is shown below. In this case, I am installing babel so I can work with ES6.

 

Installing Babel

 

All told, I think the ability to use Linux Bash on a Windows system will be very helpful from a developer perspective. I am curious as to your experiences and whether you have tried this approach.

 

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Social media & sharing icons powered by UltimatelySocial