windows 10 wsl2 default code example
Example 1: how to set wsl 2 as default
wsl --set-default-version 2
Example 2: update to wsl2 windows 10
Enable-WindowsOptionalFeature -Online -FeatureName VirtualMachinePlatform -NoRestart
wsl --set-default-version 2
Enable-WindowsOptionalFeature -Online -FeatureName VirtualMachinePlatform -NoRestart