mirror of
https://github.com/ublue-os/bazzite.git
synced 2025-02-21 18:40:00 +00:00
fix(deck): Check if micro SD card is mounted before attempting to mount
This commit is contained in:
parent
fdd8facb43
commit
1f03d05b97
@ -59,17 +59,18 @@ do_mount()
|
||||
# of the drive. Our own rule starts us as a service with --no-block, so we can wait for rules to settle here
|
||||
# safely.
|
||||
if ! udevadm settle; then
|
||||
echo "Failed to wait for \`udevadm settle\`"
|
||||
exit 1
|
||||
echo "Failed to wait for \`udevadm settle\`"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
mount_point=/mnt/sdcard
|
||||
mkdir -p "${mount_point}"
|
||||
/bin/mount "${DEVICE}" "${mount_point}"
|
||||
|
||||
if [[ $? -ne 0 ]]; then
|
||||
echo "Error mounting ${DEVICE} (status = $ret)"
|
||||
exit 1
|
||||
if [[ ! -d "${mount_point}" ]]; then
|
||||
mkdir -p "${mount_point}"
|
||||
/bin/mount "${DEVICE}" "${mount_point}"
|
||||
if [[ $? -ne 0 ]]; then
|
||||
echo "Error mounting ${DEVICE}"
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
|
||||
# Workaround for for Steam compression bug
|
||||
|
Loading…
x
Reference in New Issue
Block a user