Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Windows SubSystem For Linux setup that I like with some developers stuff mixed in

Setting Up WSL

Install A Distro:

  1. Run the following in powershell as admin Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux

  2. Install a distro (ex: Ubuntu 18.04 LTS -

  3. Open your distro you installed via the start menu, let it setup

  4. Update and upgrade

sudo apt-get update
sudo apt-get upgrade

Install and configure a terminal


choco install alacritty
To use WSL, go to %APPDATA%\alacritty\alacritty.yml, and set to use bash shell:

 program: "C:\\Windows\\System32\\wsl.exe"

Install zsh, oh-my-zsh, and nice themes and fonts

  1. Install zsh and oh my zsh
sudo apt-get install zsh
sh -c "$(curl -fsSL"
  1. Switch to use ZSH by default (nano ~/.bashrc):
if [ -t 1 ]; then
exec zsh
  1. Reload terminal (source ~/.bashrc), install powerlevel10k
git clone $ZSH_CUSTOM/themes/powerlevel10k
  1. Set to use powerlevel10k theme (nano ~/.zshrc):
  1. Reload terminal (source ~/.zshrc), install fonts:
git clone

Alternatively, grab something like

  1. Install fonts via powershell (open as admin):
Set-ExecutionPolicy Bypass
cd C:\Users\Alan\Fonts
  1. Set font for terminal

        family: Noto Mono for Powerline

    If you got a nerd font like I had above, use it instead:

        family: MesloLGM NF
      size: 9.0

    Also set the following in your .zshrc:

  2. Set a terminal theme:

# Colors (iTerm 2 default theme)
# Default colors
 background: '0x101421'
 foreground: '0xfffbf6'

# Normal colors
 black:   '0x2e2e2e'
 red:     '0xeb4129'
 green:   '0xabe047'
 yellow:  '0xf6c744'
 blue:    '0x47a0f3'
 magenta: '0x7b5cb0'
 cyan:    '0x64dbed'
 white:   '0xe5e9f0'

# Bright colors
 black:   '0x565656'
 red:     '0xec5357'
 green:   '0xc0e17d'
 yellow:  '0xf9da6a'
 blue:    '0x49a4f8'
 magenta: '0xa47de9'
 cyan:    '0x99faf2'
 white:   '0xffffff'
  1. Fix dir colors (in .zshrc):
LS_COLORS="ow=01;36;40" && export LS_COLORS

Install Dev Tools

Node and npm

  1. Install nodenv
curl -fsSL | bash
  1. Setup nodenv path (nano ~/.zshrc):
export PATH="$HOME/.nodenv/bin:$PATH"
eval "$(nodenv init -)"
  1. Install node and update npm after reloading terminal (source ~/.zshrc)
nodenv install 10.16.1
nodenv global 10.16.1
npm install -g npm@latest

Python and pip

  1. Install pyenv:
curl | bash
  1. Setup pyenv path (nano ~/.zshrc):
export PATH="/home/alan/.pyenv/bin:$PATH"
eval "$(pyenv init -)"
eval "$(pyenv virtualenv-init -)"
  1. Install dependencies, python version, and update pip after reloading terminal (source ~/.zshrc):
sudo apt-get install -y make build-essential libssl-dev zlib1g-dev libbz2-dev libreadline-dev libsqlite3-dev wget curl llvm libncurses5-dev libncursesw5-dev xz-utils tk-dev libffi-dev liblzma-dev python-openssl git
pyenv install 3.7.3
pyenv global 3.7.3
pip install --upgrade pip
Copy link

JamesHWade commented Dec 10, 2020

Thank you for sharing! This is a great guide.

I'm curious to know if you use alacritty as a standalone application or do you open in as a "profile" in Windows Terminal.

Thanks, again!


Copy link

AjkayAlan commented Dec 10, 2020

Good question @JamesHWade - honestly I need to update this, as what I am using now has definitely changed. Right now I use WSL with Windows Terminal directly, I don't use alacritty at all.

I had started a ways back with Alacritty but one I got familiar with Windows Terminal, I haven't looked back.


Copy link

JamesHWade commented Dec 11, 2020

I would be quite interested in any updates. I like my customization of Alacritty, but I'd like to see an alternative approach.


Copy link

benjaminrich commented Jun 4, 2021

Very useful. Thanks.


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment