1
0
mirror of https://github.com/ventoy/Ventoy.git synced 2025-01-15 08:45:03 -05:00

Update ventoy_lib.sh

This commit is contained in:
longpanda 2020-05-21 15:59:06 +08:00 committed by GitHub
parent 50aa5d3823
commit ac0f68f90b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -255,13 +255,22 @@ EOF
partprobe >/dev/null 2>&1 partprobe >/dev/null 2>&1
sleep 3 sleep 3
echo 'mkfs on disk partitions ...' echo 'mkfs on disk partitions ...'
while ! [ -e $PART2 ]; do for i in 1 2 3 4 5 6 7; do
echo "wait $PART2 ..." if [ -b $PART2 ]; then
sleep 1 break
else
echo "wait $PART2 ..."
sleep 1
fi
done done
if ! [ -b $PART2 ]; then
MajorMinor=$(sed "s/:/ /" /sys/class/block/${PART2#/dev/}/dev)
echo "mknod -m 0660 $PART2 b $MajorMinor ..."
mknod -m 0660 $PART2 b $MajorMinor
fi
echo "create efi fat fs ..." echo "create efi fat fs ..."
for i in 0 1 2 3 4 5 6 7 8 9; do for i in 0 1 2 3 4 5 6 7 8 9; do
if mkfs.vfat -F 16 -n EFI $PART2; then if mkfs.vfat -F 16 -n EFI $PART2; then