automount: skip some partition

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
(cherry picked from commit cb7067660611bf85d207e2a91b95d0fc9d806dac)
This commit is contained in:
lean 2022-04-03 13:24:18 +08:00 committed by Tianling Shen
parent 768d05d74e
commit 159825dbad
No known key found for this signature in database
GPG Key ID: 6850B6345C862176

View File

@ -6,7 +6,7 @@
blkdev=`dirname $DEVPATH`
basename=`basename $blkdev`
device=`basename $DEVPATH`
skip=`block info | sed 's/\(.*\): .*/\1/' | grep -q $device ; echo $?`
skip=`block info | grep -vE '(f2fs|kernel|squashfs)' | sed 's/\(.*\): .*/\1/' | grep -q $device ; echo $?`
path=$DEVPATH
if [ $basename != "block" ] && [ -z "${device##sd*}" ] && [ $skip -eq 1 ]; then