Skip to content

Instantly share code, notes, and snippets.

@DessertArbiter
Created April 16, 2022 19:40
Show Gist options
  • Save DessertArbiter/bd0ce6b63f0785bd326764c31521caf4 to your computer and use it in GitHub Desktop.
Save DessertArbiter/bd0ce6b63f0785bd326764c31521caf4 to your computer and use it in GitHub Desktop.
PowerShell script to list the names of installed WSL distros and their corresponding GUIDs
Get-ChildItem -Path HKCU:\Software\Microsoft\Windows\CurrentVersion\Lxss | Get-ItemProperty -Name DistributionName | Select-Object @{Name='Distro';Expression={$PSItem.DistributionName}},@{Name='GUID';Expression={$PSItem.PSChildName}}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment