deal with $0 having spaces in it

This commit is contained in:
Joey Hess 2013-03-20 14:11:36 -04:00
parent 05dcb95a55
commit f84b8615e5
6 changed files with 6 additions and 6 deletions

View file

@ -1,5 +1,5 @@
#!/bin/sh
base="$(dirname $0)"
base="$(dirname "$0")"
if [ ! -d "$base" ]; then
echo "** cannot find base directory (I seem to be $0)" >&2
exit 1

View file

@ -1,5 +1,5 @@
#!/bin/sh
base="$(dirname $0)"
base="$(dirname "$0")"
if [ ! -d "$base" ]; then
echo "** cannot find base directory (I seem to be $0)" >&2
exit 1

View file

@ -4,7 +4,7 @@
set -e
base="$(dirname $0)"
base="$(dirname "$0")"
if [ ! -d "$base" ]; then
echo "** cannot find base directory (I seem to be $0)" >&2

View file

@ -1,5 +1,5 @@
#!/bin/sh
base="$(dirname $0)"
base="$(dirname "$0")"
if [ ! -d "$base" ]; then
echo "** cannot find base directory (I seem to be $0)" >&2
exit 1

View file

@ -1,5 +1,5 @@
#!/bin/sh
base="$(dirname $0)"
base="$(dirname "$0")"
if [ ! -d "$base" ]; then
echo "** cannot find base directory (I seem to be $0)" >&2
exit 1

View file

@ -4,7 +4,7 @@
set -e
base="$(dirname $0)"
base="$(dirname "$0")"
if [ ! -d "$base" ]; then
echo "** cannot find base directory (I seem to be $0)" >&2