Closed ASlowTurtle closed 1 year ago
I love the new Pre-PSD menu (and the release in general). But I noticed that wiping all disks also wipes the USB stick (from which I booted). PSDResources\Prestart\PSDPrestartMenu.ps1 ` '2' { Clear-Host Write-Host "Cleaning all disks"
#Get-PhysicalDisk | Reset-PhysicalDisk -Verbose
# Borrowed (with pride) code snippet from David Segura $Disks = Get-Disk foreach ($Disk in $Disks){
$null = @" select disk $($Disk.number) clean exit "@ | diskpart.exe } Changing line 75 to $Disks = Get-Disk | Where-Object "bustype" -ne "usb"` should prevent that.
Changing line 75 to
We're in the process of fixing this, thank you very much for the spotting of the issue and the excellent info provided!
Issues has been fixed in the latest update, thank you for the heads-up.
I love the new Pre-PSD menu (and the release in general). But I noticed that wiping all disks also wipes the USB stick (from which I booted). PSDResources\Prestart\PSDPrestartMenu.ps1 ` '2' { Clear-Host Write-Host "Cleaning all disks"
Get-Disk | Clear-Disk -RemoveData -RemoveOEM -Confirm:$false -Verbose
#Get-PhysicalDisk | Reset-PhysicalDisk -Verbose
Using diskpart due to issues with Clear-Disk
$null = @" select disk $($Disk.number) clean exit "@ | diskpart.exe }
Changing line 75 to
$Disks = Get-Disk | Where-Object "bustype" -ne "usb"` should prevent that.