Run Bash Shell On Windows 10

Microsoft has announced “Bash on Ubuntu on Windows” at Microsoft’s annual Build conference in San Francisco. This announcement was made by Kevin Gallo in the Day One Keynote. This is a new developer feature, which has been included in Windows 10 "Anniversary" update. It allows you to run native user-mode Linux shells and command-line tools unchanged on Windows.
After turning on the Developer Mode in Windows Settings and adding the new Features, you run bash and are prompted to get Ubuntu on Windows from Canonical via the Windows Store, such as this:
Image Source:
This is not Bash or Ubuntu running in a VM. This is real native Bash Linux binary running on Windows itself. It is fast and light and the real binaries. This image is a genuine Ubuntu on top of Windows with the entire Linux tools such as awk, sed, grep, vi, etc. The binaries are downloaded by you, using apt-get-just as on Linux, because it is Linux. You can apt-get and download other tools such as Ruby, Redis, emacs, and so on. This is excellent for developers who use a diverse set of tools.
This runs on 64-bit Windows and does not use virtual machines. If you want to run Bash on Windows, you have a few choices: 
  • Cygwin - GNU command line utilities compiled for Win32 with great native Windows integration. But it's not Linux.
  • HyperV and Ubuntu - Run an entire Linux VM (dedicating x gigs of RAM, and x gigs of disk) and then remote into it (RDP, VNC, ssh)
  • Docker is also an option to run a Linux container, under a HyperV VM. 
Running bash on Windows hits the sweet spot. It behaves similar to Linux because it executes real Linux binaries. All you need to do is hit the Windows Key and type bash.
After you are setup, run apt-get update and get a few developer packages. If you want Redis and Emacs, all you need to do is an apt-get install emacs23 to get emacs. Note, this is actual emacs retrieved from Ubuntu’s feed.
Image Source:
It is to be noted that this is not about Linux Server or Server workloads. This is a eveloper-focused release which removes major barriers for developers who want or need to use Linux tools as part of their workflow. Here is a Redis via apt-get, and now you will be able to run it in standalone mode.
Image Source:
This is the bash to run Redis while writing ASP.NET apps in Virtual Studio, which uses Redis cache. It can later deploy to Azure using the Azure Redis Cache.
As stated by Scott Hanselman via blog
"Keep an eye out at for technical details in the coming weeks. There's also some great updates to the underlying console with better support for control codes, ANSI, VT100, and lots more. This is an early developer experience and the team will be collection feedback and comments. You'll find Ubuntu on Windows available to developers as a feature in a build Windows 10 coming soon. Expect some things to not work early on, but have fun exploring and seeing how bash on Ubuntu on Windows fits into your developer workflow!"

Build smarter apps with Machine Learning, Bots, Cognitive Services - Start free.

Start Learning Now