Homebrew v2.0 officially supports Windows 10 (WSL) and Linux that is released on February 2, 2019.
This article how to setup WSL that is needed when you setting up Homebrew on Windows 10.
(1) Select “Settings” from the Start Menu.
(2) Click “Apps”.
(3) Click “Programs and Features” link. This link is located below “Related settings”. If the width of the window is narrow, this links may be below apps list.
(4) Click “Turn Windows features on or off” link. It is in the left column in the window.
(5) Turn on “Windows Subsytem for Linux” and click “OK” button.
(6) Installation will be started. After completed, click “Restart now” button to restart your PC.
Install the Linux Distribution
The Linux Distribution for WSL can be installed from Microsoft Store. You can install any distribution you want. In this article, install the Ubuntu. Follow to steps below.
(1) Search with keyword “Ubuntu” in the Microsoft Store App.
(2) Click the “Ubuntu”.
(3) Click the “Install” button.
(4) “Launch” button will be appeared when the installation is completed. Click it.
Setting up Ubuntu
Shell will be launched. First time, you need to setup the Ubuntu.
(1) Installation will be started with message below. Wait until completed.
Installing, this may take a few minutes...
(2) You need to create the default UNIX user account. Enter the new user name.
Please create a default UNIX user account. The username does not need to match your Windows username.
For more information visit: https://aka.ms/wslusers
Enter new UNIX username:
(3) Next, you need enter the password for the new account.
Retype new password:
Now, you can use Ubuntu on the WSL.