]> glassweightruler.freedombox.rocks Git - Ventoy.git/blobdiff - IMG/cpio/ventoy/hook/ventoy-hook-lib.sh
update CI build script
[Ventoy.git] / IMG / cpio / ventoy / hook / ventoy-hook-lib.sh
index f9dae7aed3cc358c1fced29ff18201ab30794f10..689b68c8d857169743f156890f36250f994239d5 100644 (file)
@@ -102,6 +102,16 @@ wait_for_usb_disk_ready() {
        done
 }
 
        done
 }
 
+check_usb_disk_ready() {
+    if echo $1 | $EGREP -q "nvme|mmc"; then
+        vtpart2=${1}p2
+    else
+        vtpart2=${1}2
+    fi
+    
+    [ -e "${vtpart2}" ]
+}
+
 is_ventoy_disk() {
     if $VTOY_PATH/tool/vtoydump -f $VTOY_PATH/ventoy_os_param -c "$1"; then
         $BUSYBOX_PATH/true
 is_ventoy_disk() {
     if $VTOY_PATH/tool/vtoydump -f $VTOY_PATH/ventoy_os_param -c "$1"; then
         $BUSYBOX_PATH/true