Merge pull request #1233 from karolszklarski/patch-1

Target of nand-sata-install can be md raid
This commit is contained in:
Igor Pečovnik 2019-01-18 19:28:41 +01:00 committed by GitHub
commit 8e23ae691f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -481,7 +481,7 @@ format_disk()
check_partitions()
{
IFS=" "
AvailablePartitions=$(lsblk -l | awk -F" " '/ part / {print $1}' | egrep '^sd|^nvme')
AvailablePartitions=$(lsblk -l | awk -F" " '/ part | raid..? / {print $1}' | egrep '^sd|^nvme|^md')
if [[ -z $AvailablePartitions ]]; then
dialog --title "$title" --backtitle "$backtitle" --colors --msgbox \
"\n\Z1There are no avaliable partitions. Please create them.\Zn" 7 60
@ -489,7 +489,7 @@ check_partitions()
apt-get -y -q install gdisk >/dev/null 2>&1
gdisk /dev/$diskcheck
fi
AvailablePartitions=$(lsblk -l | awk -F" " '/ part / {print $1}' | egrep '^sd|^nvme' | sed 's|^|/dev/|' | nl | xargs echo -n)
AvailablePartitions=$(lsblk -l | awk -F" " '/ part | raid..? / {print $1}' | egrep '^sd|^nvme|^md' | uniq | sed 's|^|/dev/|' | nl | xargs echo -n)
PartitionOptions=($AvailablePartitions)
PartitionCmd=(dialog --title "Select destination:" --backtitle "$backtitle" --menu "\n$infos" 10 60 16)