diff options
author | JozanLeClerc <bousset.rudy@gmail.com> | 2019-11-17 15:15:14 +0100 |
---|---|---|
committer | JozanLeClerc <bousset.rudy@gmail.com> | 2019-11-17 15:15:14 +0100 |
commit | a68d373406f5f851af92de1cf8088ec2d15e65aa (patch) | |
tree | 143c50fd42b4e0e22ae60c9e87a7fbc0338fe1f1 | |
parent | Trying wipefs (diff) | |
download | arch-installer-a68d373406f5f851af92de1cf8088ec2d15e65aa.tar.gz arch-installer-a68d373406f5f851af92de1cf8088ec2d15e65aa.tar.bz2 arch-installer-a68d373406f5f851af92de1cf8088ec2d15e65aa.tar.xz arch-installer-a68d373406f5f851af92de1cf8088ec2d15e65aa.tar.zst arch-installer-a68d373406f5f851af92de1cf8088ec2d15e65aa.zip |
changes, should whipe out partitions as well
-rwxr-xr-x | joes-arch-install-UEFI.sh | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/joes-arch-install-UEFI.sh b/joes-arch-install-UEFI.sh index 8ced21c..d932b38 100755 --- a/joes-arch-install-UEFI.sh +++ b/joes-arch-install-UEFI.sh @@ -365,7 +365,15 @@ echo "\ # # #=================================#" echo && echo -dd if=/dev/zero of="$drv" bs=512 count=1 > /dev/null +basepartc=$(lsblk "$drv" | grep -c part) +i=1 +while [[ $i -le $basepartc ]]; do + towhipe=$(lsblk "$drv" | grep part | awk '{print $1}' | rev | cut -c -1 | rev | awk "NR==$i") + dd if=/dev/zero of="$drv$towhipe" bs=1M status=progress + ((i++)) +done +echo "Whiping disk. This step may take a while." +dd if=/dev/zero of="$drv" bs=1M status=progress wipefs --all --force "$drv" fdisk "$drv" << FDISK_INPUT o |