Skip to content
Davood Dorostkar edited this page Aug 18, 2024 · 5 revisions

Setup

  • install default ubuntu
wsl --install
  • set as default version
wsl --set-default <Name>

Check

  • list online versions
wsl -l --online
  • list installed versions
wsl -l -v

Start/Stop

  • run in home directory
wsl --cd ~
  • run as a user
wsl -u <user>
  • stop a distro
wsl -t <Distribution Name>
  • stop all
wsl --shutdown

Remove

  • uninstall a dirsto
wsl --unregister <DistributionName>

Import/Export

  • import and export as .tar
wsl --export <Distribution Name> <FileName>
wsl --import <Distribution Name> <InstallLocation> <FileName>

VSCode

run vscode in wsl and develop in windows

reference

Clone this wiki locally