Improve support of directory names with spaces
Support path names starting with the '-' character

When the path begins with the '-' character, shell commands can
interpret the path name as an option.
To prevend that, '--' needs to be inserted before the path, which tells
the command that there are no more options.
Make the the scripts POSIX compatible

Under various distributions, /bin/sh can point to a shell different
than /bin/bash (e.g. ash, dash). On some platforms, bash might not even
be available.
Therefore the bash specific features and commands should not be used.
Merge pull request #3 from emaskovsky/master

Improve support of directory names with spaces and POSIX compatibility