system: Let addsite always make DIR absolute.
authorroot <root@template.drsnuggles.stderr.nl>
Fri, 7 Nov 2008 11:40:45 +0000 (12:40 +0100)
committerroot <root@template.drsnuggles.stderr.nl>
Fri, 7 Nov 2008 11:40:45 +0000 (12:40 +0100)
usr/local/bin/addsite

index 44d39b88cbfced4143504c629dcb6e01faa381dc..d2f515e7d64b1fb6b71d1ccef8b89d0d21a22e41 100755 (executable)
@@ -21,7 +21,10 @@ PHP_CONFIG=conf/php.ini.override
 # PHP error logfile to set error_log to
 PHP_ERRORLOG=logs/php.log
 
-DIR=$1
+# Get dir, but make it absolute
+cd "$1"
+DIR=`pwd`
+
 
 if [ -e "$DIR" -a ! -d "$DIR" ]; then
        echo "$DIR" must be a directory, or not exist yet.