From ea1f82fd16c75b62405758dc6aeb783cf4758f49 Mon Sep 17 00:00:00 2001 From: Jonas Tobias Hopusch Date: Tue, 10 Jan 2023 21:12:03 +0100 Subject: [PATCH] Resolve issue with script accidentally detecting unmounted image as mounted --- cd-mount.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cd-mount.sh b/cd-mount.sh index ba731f4..5044222 100755 --- a/cd-mount.sh +++ b/cd-mount.sh @@ -83,7 +83,7 @@ for image in "${imageFiles[@]}"; do # Check if there's already an image mounted at the destination #shellcheck disable=SC2006 fullPathMountDir="`cd "$mountDirName" && pwd`" - if grep "^fuseiso $fullPathMountDir" /proc/mounts >/dev/null 2>&1; then + if grep "^fuseiso $fullPathMountDir " /proc/mounts >/dev/null 2>&1; then echo "Something is already mounted to $mountDirName. Skipping" continue fi