]> git.pld-linux.org Git - packages/autofs.git/commitdiff
- cosmetics
authorElan Ruusamäe <glen@pld-linux.org>
Wed, 29 Jul 2009 05:36:25 +0000 (05:36 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    autofs.init -> 1.33

autofs.init

index eae89e08562114ae9fe04896a6407f3c2951154a..8416ac46c42161f95b2621f82eb7c848739ff039 100644 (file)
@@ -53,9 +53,9 @@ if [ -f /etc/autofs/auto.master ]; then
                    continue
                fi
 
-               maptype=`echo $map | cut -f1 -d:`
+               maptype=${map%%:*}
                if [ "$maptype" = "$map" ]; then
-                       map=`echo "/etc/autofs/$map" | sed -e 's:^/etc\/autofs//:/:'`
+                       map=`echo "/etc/autofs/$map" | sed -e 's:^/etc/autofs//:/:'`
                        options=`echo "$options" | sed -e 's/\(^\|[ \t]\)-/\1/g'`
                        if [ -x $map ]; then
                                echo "$DAEMON --timeout ${TIMEOUT} ${OPTIONS} $dir program $map $options"
@@ -65,10 +65,10 @@ if [ -f /etc/autofs/auto.master ]; then
                                echo "$DAEMON --timeout ${TIMEOUT} ${OPTIONS} $dir `basename $map` $options"
                        fi
                else
-                       map=`echo $map | cut -f2- -d:`
-                       if [ ! -z "$map" ]; then
+                       map=${map#*/}
+                       if [ "$map" ]; then
                                if [ "$maptype" = "file" ]; then
-                                       map=`echo "/etc/autofs/$map" | sed -e 's:^/etc\/autofs//:/:'`
+                                       map=`echo "/etc/autofs/$map" | sed -e 's:^/etc/autofs//:/:'`
                                fi
                                echo "$DAEMON --timeout $TIMEOUT ${OPTIONS} $dir $maptype $map $options"
                        fi
This page took 0.050113 seconds and 4 git commands to generate.