#! /bin/sh
#
# Create the requested directories
# We don't want to use IFS, because that will drop the initial / (which may or
# may not be present)
for dir in $@ ; do
    dir=`echo $dir | sed 's%/% /%g'`
    path_to_date=''
    for path in $dir ; do
	path_to_date="$path_to_date$path"
	if [ ! -d $path_to_date ] ; then 
 	    echo "mkdir $path_to_date"
	    if mkdir $path_to_date ; then 
	        :
	    else
	        echo "Failed to create directory $path_to_date"
	        exit 1
	    fi
	fi
    done
done
