Use realpath to remove useless slashes from path

This commit is contained in:
Krizsán Péter 2024-11-23 19:54:06 +01:00
parent 0c7e499af6
commit 5f1c83a37a

View File

@ -41,8 +41,9 @@ createFstab()
fi fi
# If a mount point is given then we generate fstab based on that mount point. # If a mount point is given then we generate fstab based on that mount point.
DIR_ROOT="$1 "
DIR_BOOT="$1/boot " DIR_ROOT="$(realpath -sm "$1") "
DIR_BOOT="$(realpath -sm "$1")/boot "
else else
# No mount point is given. We generate fstab for the current running system. # No mount point is given. We generate fstab for the current running system.
DIR_ROOT="/ " DIR_ROOT="/ "