config_mypath(): fix mkdir usage + writing to /etc/grml/my_path 0.8.7
authorMichael Prokop <devnull@localhost>
Mon, 19 May 2008 23:09:56 +0000 (01:09 +0200)
committerMichael Prokop <devnull@localhost>
Mon, 19 May 2008 23:09:56 +0000 (01:09 +0200)
autoconfig.functions
debian/changelog

index 48d98da..ccca421 100755 (executable)
@@ -4,7 +4,7 @@
 # Authors:       grml-team (grml.org), (c) Klaus Knopper <knopper@knopper.net>, (c) Michael Prokop <mika@grml.org>
 # Bug-Reports:   see http://grml.org/bugs/
 # License:       This file is licensed under the GPL v2.
-# Latest change: Sam Mai 17 22:15:54 CEST 2008 [mika]
+# Latest change: Tue May 20 01:09:30 CEST 2008 [mika]
 ################################################################################
 
 # {{{ path, variables, signals, umask, zsh
@@ -1929,11 +1929,11 @@ if checkbootparam "mypath" ; then
    for i in $(echo $MY_PATH | sed 's/:/\n/g') ; do
        if ! [ -d "$i" ] ; then
           einfo "Creating directory $i"
-          mkdir -d "$i" ; eend $?
+          mkdir -p "$i" ; eend $?
        fi
    done
+   grep -q "${MY_PATH}" /etc/grml/my_path || echo "${MY_PATH}" >> /etc/grml/my_path ; eend $?
    eoutdent
-   echo "$MY_PATH" >> /etc/grml/my_path ; eend $?
 fi
 }
 # }}}
index 5c253e5..3d7e446 100644 (file)
@@ -1,3 +1,10 @@
+grml-autoconfig (0.8.7) unstable; urgency=low
+
+  * config_mypath(): fix mkdir usage and write directories just once
+    to /etc/grml/my_path.
+
+ -- Michael Prokop <mika@grml.org>  Tue, 20 May 2008 01:01:37 +0200
+
 grml-autoconfig (0.8.6) unstable; urgency=low
 
   * config_syslog(): support other syslog daemons than syslog-ng as well.