Create the standard directories in the rebuildfstab script instead of grml-autoconfig.
authorUlrich Dangel <uli@spamt.net>
Mon, 2 Jan 2012 09:54:10 +0000 (10:54 +0100)
committerUlrich Dangel <uli@spamt.net>
Mon, 2 Jan 2012 09:58:43 +0000 (10:58 +0100)
With this change grml-udev-rebuildfstab is the primary place to specify
MOUNTPOINT_PREFIX.

scripts/grml-udev-rebuildfstab

index 5c5e8d5..9aaf08f 100755 (executable)
@@ -67,6 +67,14 @@ if grep -q ' $MOUNTPOINT_PREFIX ' /proc/mounts ; then
    bailout 1
 fi
 
+# default directories {{{
+if [ -d "$MOUNTPOINT_PREFIX" ] ; then
+   [ -d "$MOUNTPOINT_PREFIX/floppy" ] || mkdir "$MOUNTPOINT_PREFIX/floppy"
+   [ -d "$MOUNTPOINT_PREFIX/cdrom" ]  || mkdir "$MOUNTPOINT_PREFIX/cdrom"
+   [ -d "$MOUNTPOINT_PREFIX/test" ]   || mkdir "$MOUNTPOINT_PREFIX/test"
+fi
+# }}}
+
 # make sure we have the $MNTFILE before reading/writing into it
 if [ -z "$NO_AUTO_FILE" ] ; then
    [ -r $MNTFILE ] || touch $MNTFILE