Streamline WSL distribution name
This commit is contained in:
parent
9a62c37880
commit
846e3fee5a
|
@ -163,6 +163,16 @@ $null = New-Module {
|
||||||
Copy-Item -Recurse -Force (Get-AppxPackage "*Ubuntu*").InstallLocation $wslLocation;
|
Copy-Item -Recurse -Force (Get-AppxPackage "*Ubuntu*").InstallLocation $wslLocation;
|
||||||
Set-UserPermissions $wslLocation;
|
Set-UserPermissions $wslLocation;
|
||||||
& "$wslLocation\ubuntu.exe" install --root;
|
& "$wslLocation\ubuntu.exe" install --root;
|
||||||
|
wsl --shutdown;
|
||||||
|
|
||||||
|
& {
|
||||||
|
$tempDisk = New-TemporaryFile;
|
||||||
|
Move-Item $wslDisk $tempDisk;
|
||||||
|
wsl --deregister Ubuntu;
|
||||||
|
Move-Item $tempDisk $wslDisk;
|
||||||
|
wsl --import-in-place $distribution $wslDisk;
|
||||||
|
};
|
||||||
|
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue