mirror of
https://github.com/ventoy/Ventoy.git
synced 2025-08-28 00:11:15 +00:00
1.0.11 release
This commit is contained in:
@@ -111,17 +111,31 @@ if ! check_tool_work_ok; then
|
||||
fi
|
||||
|
||||
grep "^$DISK" /proc/mounts | while read mtline; do
|
||||
mtpnt=$(echo $mtline | awk '{print $DISK}')
|
||||
mtpnt=$(echo $mtline | awk '{print $2}')
|
||||
vtdebug "Trying to umount $mtpnt ..."
|
||||
umount $mtpnt >/dev/null 2>&1
|
||||
done
|
||||
|
||||
if swapon -s | grep -q "^${DISK}[0-9]"; then
|
||||
swapon -s | grep "^${DISK}[0-9]" | awk '{print $1}' | while read line; do
|
||||
vtdebug "Trying to swapoff $line ..."
|
||||
swapoff $line
|
||||
done
|
||||
fi
|
||||
|
||||
|
||||
if grep "$DISK" /proc/mounts; then
|
||||
vterr "$DISK is already mounted, please umount it first!"
|
||||
cd $OLDDIR
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if swapon -s | grep -q "^${DISK}[0-9]"; then
|
||||
vterr "$DISK is used as swap, please swapoff it first!"
|
||||
cd $OLDDIR
|
||||
exit 1
|
||||
fi
|
||||
|
||||
|
||||
if [ "$MODE" = "install" ]; then
|
||||
vtdebug "install ventoy ..."
|
||||
@@ -230,6 +244,12 @@ if [ "$MODE" = "install" ]; then
|
||||
|
||||
vtinfo "esp partition processing ..."
|
||||
|
||||
sleep 1
|
||||
mtpnt=$(grep "^${DISK}2" /proc/mounts | awk '{print $2}')
|
||||
if [ -n "$mtpnt" ]; then
|
||||
umount $mtpnt >/dev/null 2>&1
|
||||
fi
|
||||
|
||||
if [ "$SECUREBOOT" != "YES" ]; then
|
||||
mkdir ./tmp_mnt
|
||||
|
||||
@@ -239,9 +259,14 @@ if [ "$MODE" = "install" ]; then
|
||||
vtdebug "mounting part2 success"
|
||||
break
|
||||
fi
|
||||
|
||||
mtpnt=$(grep "^${DISK}2" /proc/mounts | awk '{print $2}')
|
||||
if [ -n "$mtpnt" ]; then
|
||||
umount $mtpnt >/dev/null 2>&1
|
||||
fi
|
||||
sleep 2
|
||||
done
|
||||
|
||||
|
||||
rm -f ./tmp_mnt/EFI/BOOT/BOOTX64.EFI
|
||||
rm -f ./tmp_mnt/EFI/BOOT/grubx64.efi
|
||||
rm -f ./tmp_mnt/EFI/BOOT/MokManager.efi
|
||||
|
@@ -121,6 +121,7 @@ function distro_specify_initrd_file {
|
||||
fi
|
||||
}
|
||||
|
||||
|
||||
function distro_specify_initrd_file_phase2 {
|
||||
if [ -f (loop)/boot/initrd.img ]; then
|
||||
vt_linux_specify_initrd_file /boot/initrd.img
|
||||
@@ -132,6 +133,8 @@ function distro_specify_initrd_file_phase2 {
|
||||
vt_linux_specify_initrd_file /boot/iniramfs.igz
|
||||
elif [ -f (loop)/initrd-x86_64 ]; then
|
||||
vt_linux_specify_initrd_file /initrd-x86_64
|
||||
elif [ -f (loop)/live/initrd.img ]; then
|
||||
vt_linux_specify_initrd_file /live/initrd.img
|
||||
|
||||
fi
|
||||
}
|
||||
@@ -453,7 +456,7 @@ function common_menuentry {
|
||||
#############################################################
|
||||
#############################################################
|
||||
|
||||
set VENTOY_VERSION="1.0.10"
|
||||
set VENTOY_VERSION="1.0.11"
|
||||
|
||||
# Default menu display mode, you can change it as you want.
|
||||
# 0: List mode
|
||||
|
Reference in New Issue
Block a user