This is an old revision of the document!
Table of Contents
Windows Subsystem for Linux (WSL)
I'll grudgingly admit that Windows Subsytem for Linux isn't bad like I thought it would be. That said, there are several things you might want to do to make it more livable.
Enabling WSL
First, to enable WSL at all (from here), in adminstrator powershell:
Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux
Then, it still being Windows, you have to restart.
Installing distro
Windows Store is a garbage zone. Here's the spell for skipping that part (from here). Just download this URL and double click what you get:
https://aka.ms/wsl-ubuntu-1804
Other URLs exist for other distros; you're on your own for that.
Making it Launchy-launchable
The distro will be installed as an "app", which is Windows 10 speak for "dumbed down program that's treated in special ways that break normal workflows". If you have classic Start and Launchy, to make it work with Launchy:
- Make a shortcut of the "app", then put the shortcut into the classic start menu programs list.
Basic packages
The default package set is actually not bad. But here's what's missing:
sudo apt install lynx links binutils zip unzip gdb
Symlinks
To get to places easily:
ln -s /mnt/c/Users/$USER ~ sudo ln -s /mnt/c /c
"Open Linux Shell Here" context menu
It turns out there already is one by default, but it only shows if you shift right click. To make it always visible (per here):
- Download and run "ExecTI" to allow you to run regedit as TrustedInstaller (more privileges than admin)
- Run regedit using the tool
- In
HKEY_CLASSES_ROOT\Directory\shell\WSL
, delete the keyExtended
Keyboard scrolling
By default, there's no keyboard shortcut to scroll the Windows terminal. Per here, a quick duct tape solution is to use the following script in AutoHotKey:
#IfWinActive ahk_class ConsoleWindowClass +PgUp:: Send {WheelUp} Return +PgDn:: Send {WheelDown} Return #IfWinActive