quote path variables in whatnow2.sh
authorPhilipp Takacs <philipp@bureaucracy.de>
Fri, 17 Feb 2017 15:05:57 +0000 (16:05 +0100)
committerPhilipp Takacs <philipp@bureaucracy.de>
Fri, 17 Feb 2017 15:05:57 +0000 (16:05 +0100)
without qoutes this causes error with spaces or other
special charecter in the path or filename.

uip/whatnow2.sh

index 2040725..59e91b7 100755 (executable)
@@ -73,9 +73,9 @@ get_realpath()
 {
        reldir=`dirname "$1"`
        filename=`basename "$1"`
-       cd $reldir
+       cd "$reldir"
        echo "$PWD/$filename"
-       cd $OLDPWD
+       cd "$OLDPWD"
 }
 
 set_lasteditor()