Brief: This beginners tutorial shows you how to install bash on Windows.
Linux on Windows is a reality, thanks to the partnership between Canonical (parent company of Ubuntu) and Microsoft. When Microsoft CEO announced that Bash shell is coming to Windows, a number of people just couldn’t believe it. #BashOnWindows trended on Twitter for days, such was the impact of this news.
But Bash on Windows was not available to everyone immediately. People had to install Windows 10 technical preview to install Linux on Windows 10. But this is not the case anymore. Windows 10 anniversary upgrade is here and now you can easily get bash on Windows. But before we go on installing bash on Windows, let me tell you a little more about it.
What is Bash on Windows?
Bash on Windows provides a Windows subsystem and Ubuntu Linux runs atop it. It is not a virtual machine or an application like Cygwin. It is complete Linux system inside Windows 10. I recommend reading this article to know more about Bash on Windows.
How to install Bash on Windows
There are a few prerequisites of installing bash on Windows. You must have:
- A good internet connection (as it needs to download over a GB)
- Windows 10 anniversary update
If you are using Windows 10 right now, you can go to this page and get the Windows 10 anniversary upgrade. Otherwise, you can download and install Windows 10 anniversary upgrade.
Once you have made sure that you have Windows 10 anniversary upgrade, let’s see how to get bash shell on Windows 10.
Press Windows Key + I to access Windows system settings. In here, go to Update & Security:
In here, from the left side pane, choose ‘For developers’. You’ll see an option of ‘Developer mode’. Enable it.
Now search for Control Panel and in Control Panel, click on “Programs”:
In Programs, click “Turn Windows Features On or Off”:
When you do this, you’ll see several Windows features. Look for “Windows Subsystem for Linux” and enable it.
You’ll need to restart the system after doing this.
After restarting the computer, click the start button and search for “bash”.
When you run it for the first time, you’ll be given the option to download and install Ubuntu. You’ll be asked to create username and password during this process. It will install entire Ubuntu Linux, so have patience as it will take some time in downloading and installing Linux on Windows.
Once this is done, go back to Start menu and search for Ubuntu or Bash.
Now you have got a command line version of Ubuntu Linux. You can use apt to install various command line tools in it.
I hope you find this tutorial helpful to install bash on Windows 10. I let you play with Linux inside Windows. If you have questions or suggestions, feel free to ask.