You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Jan 30, 2025. It is now read-only.
echowarn "Mime check has been disabled. Skipping."
198
+
echowarn "Mime check has been disabled with \`--no-mime-check'. Skipping."
187
199
return 0
188
200
fi
189
-
if [ !"$mimetype"=="application/x-iso9660-image" ];then
190
-
failAndExit "Provided file \`$selectedIsoFile' doesn't seem to be an ISO file (wrong mime type: \`$mimetype').\\nTry it with \`--no-mime-check' option."
201
+
[ "$mimetype"=="application/octet-stream" ]
202
+
isOctetStream=$?
203
+
if [ "$strictMimeCheck"=='true' ] &&((isOctetStream ==0));then
failAndExit "There is no USB drive connected to your system.\\nUse --no-usb-check to bypass this detection at your own risk, or replug an plugged device which is likely ejected."
451
+
echoerr "There is no USB drive connected to your system."
452
+
echowarn "Use \`--no-usb-check' to bypass this detection at your own risk, or replug an plugged device which is likely ejected."
453
+
echoerr "Exiting $scriptName..."
454
+
exit 1
418
455
fi
419
456
fi
420
457
selectedPartition="${selectedDevice}1"
@@ -440,7 +477,10 @@ assertDeviceIsUSB() {
440
477
fi
441
478
deviceType=$(getDeviceType "$selectedDevice")
442
479
if [ "$deviceType"!="usb" ] ;then
443
-
failAndExit "The device you selected is not connected through USB (found BUS: \`$deviceType').\\nUse \`--no-usb-check' option to bypass this limitation at your own risks."
480
+
echoerr "The device you selected is not connected through USB (found BUS: \`$deviceType')."
481
+
echowarn "Use \`--no-usb-check' option to bypass this limitation at your own risks."
482
+
echoerr "Exiting $scriptName..."
483
+
exit 1
444
484
fi
445
485
echogood "The selected device \`$selectedDevice' is connected through USB."
0 commit comments