Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/ClusterM/hakchi.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel <790119+DanTheMan827@users.noreply.github.com>2017-11-28 21:40:29 +0300
committerDaniel <790119+DanTheMan827@users.noreply.github.com>2017-11-28 22:44:58 +0300
commitb9d19c900d3bf3f5e2738ca4e4deb72df0ae34a5 (patch)
tree778ede765b74c11e6bb9358f1f3279c82504ea39
parentff9b6748136b743b875cd456b0caec531f73ae43 (diff)
mount USB as RW if transfer folder exists or cfg_usb_rw=y
-rw-r--r--mod/hakchi/rootfs/etc/preinit.d/b0040_usb5
1 files changed, 3 insertions, 2 deletions
diff --git a/mod/hakchi/rootfs/etc/preinit.d/b0040_usb b/mod/hakchi/rootfs/etc/preinit.d/b0040_usb
index 156f711..4b0df43 100644
--- a/mod/hakchi/rootfs/etc/preinit.d/b0040_usb
+++ b/mod/hakchi/rootfs/etc/preinit.d/b0040_usb
@@ -19,10 +19,11 @@ checkUsbStorage(){
mount -o $ro "$disk" "$mountpoint/media" || return 1
local saves="$modname/saves"
- if [ -d "$mountpoint/media/$saves" ]; then
+
+ if [ -d "$mountpoint/media/$saves" ] || [ -d "$mountpoint/media/$modname/transfer" ] || [ "$cfg_usb_rw" == "y" ]; then
mount -o remount,$rw "$disk"
- mount_bind "$mountpoint/media/$saves" "$mountpoint/var/lib/clover/profiles/0"
fi
+ [ -d "$mountpoint/media/$saves" ] && mount_bind "$mountpoint/media/$saves" "$mountpoint/var/lib/clover/profiles/0"
return 0
}