Skip to content

Commit

Permalink
Do not install a distro on re-install of WSL
Browse files Browse the repository at this point in the history
  • Loading branch information
sirredbeard committed Jun 5, 2023
1 parent 8cfc405 commit ff8ff61
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions wsl-reset.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ switch ($arg) {
if (-not (Get-AppxPackage *WindowsSubsystemForLinux* | Remove-AppxPackage -ErrorAction SilentlyContinue 2>$null)) {
Disable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux -ErrorAction SilentlyContinue 2>$null
}
wsl.exe --install --no-launch
wsl.exe --install --no-launch --no-distribution
Write-Host "WSL has been shutdown and re-installed."
}
"--destructive-reset" {
Expand All @@ -51,7 +51,7 @@ switch ($arg) {
if (-not (Get-AppxPackage *WindowsSubsystemForLinux* | Remove-AppxPackage -ErrorAction SilentlyContinue 2>$null)) {
Disable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux -ErrorAction SilentlyContinue 2>$null
}
wsl.exe --install --no-launch
wsl.exe --install --no-launch --no-distribution
Write-Host "WSL has been shutdown, all distros unregistered, and WSL has been re-installed."
}
default {
Expand Down

0 comments on commit ff8ff61

Please sign in to comment.