From 6e74b6b357680e58d0b51b8808a566c8996a5d90 Mon Sep 17 00:00:00 2001 From: "Nicolas S. Montanaro" <7397825+99z@users.noreply.github.com> Date: Fri, 28 Feb 2025 13:48:17 +0000 Subject: [PATCH] support mount.exfat-fuse helper (#80) * handle mount.exfat-fuse * undo path change * normalize tabs * try kernel mount, then fuse * conditional --- 03-Game-Installer.sh | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/03-Game-Installer.sh b/03-Game-Installer.sh index 4256187..1a90a86 100755 --- a/03-Game-Installer.sh +++ b/03-Game-Installer.sh @@ -680,7 +680,23 @@ echo >> "${LOG_FILE}" # Syncing PS2 games echo "Mounting OPL partition" | tee -a "${LOG_FILE}" mkdir "${TOOLKIT_PATH}"/OPL 2>> "${LOG_FILE}" + sudo mount ${DEVICE}3 "${TOOLKIT_PATH}"/OPL + +# Handle possibility host system's `mount` is using Fuse +if [ $? -ne 0 ] && hash mount.exfat-fuse; then + sudo mount.exfat-fuse ${DEVICE}3 "${TOOLKIT_PATH}"/OPL +fi + +if [ $? -ne 0 ]; then + echo + echo + echo "Error: Failed to mount ${DEVICE}3 - did you run 01-Setup.sh?" + read -n 1 -s -r -p "Press any key to exit..." + echo + exit 1; +fi + echo | tee -a "${LOG_FILE}" echo "Syncing PS2 games..." | tee -a "${LOG_FILE}" sudo rsync -r --progress --ignore-existing --delete --exclude=".*" "${GAMES_PATH}/CD/" "${TOOLKIT_PATH}/OPL/CD/" 2>>"${LOG_FILE}" | tee -a "${LOG_FILE}" @@ -954,4 +970,4 @@ echo | tee -a "${LOG_FILE}" echo "Game installer script complete." | tee -a "${LOG_FILE}" echo read -n 1 -s -r -p "Press any key to exit..." -echo \ No newline at end of file +echo