Skip to content

Commit 9a92e7d

Browse files
authored
Merge pull request #16 from mathieulj/master
Tolerate quoted UUID syntax in /etc/fstab. This makes the script more robust regarding the way that UUIDs are specified.
2 parents 61624c4 + 56f0c8d commit 9a92e7d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

usbmount

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ if [ "$1" = add ]; then
106106
log info "executing command: mount $DEVNAME"
107107
mount $DEVNAME || log err "mount by DEVNAME with $DEVNAME wasn't successful; return code $?"
108108

109-
elif grep -q "^[[:blank:]]*UUID=$UUID" /etc/fstab; then
109+
elif grep -q "^[[:blank:]]*UUID=\"?$UUID\"?" /etc/fstab; then
110110
log info "executing command: mount -U $UUID"
111111
mount -U $UUID || log err "mount by UUID with $UUID wasn't successful; return code $?"
112112

0 commit comments

Comments
 (0)