fix empty paths
This commit is contained in:
parent
c15b0eda2e
commit
507f9426a4
1 changed files with 8 additions and 6 deletions
14
gis
14
gis
|
|
@ -45,12 +45,14 @@ while (( "$#" )); do
|
||||||
done
|
done
|
||||||
|
|
||||||
# Add $GIS_PATH or current work directory to paths if none is given
|
# Add $GIS_PATH or current work directory to paths if none is given
|
||||||
if [ "$GIS_PATH" ]; then
|
if [ "${paths[*]}" == "" ]; then
|
||||||
OLDIFS=$IFS
|
if [ "$GIS_PATH" ]; then
|
||||||
IFS=":" read -r -a paths <<< "$GIS_PATH"
|
OLDIFS=$IFS
|
||||||
IFS=$OLDIFS
|
IFS=":" read -r -a paths <<< "$GIS_PATH"
|
||||||
elif [ "${paths[*]}" == "" ]; then
|
IFS=$OLDIFS
|
||||||
paths=("$(pwd)")
|
else
|
||||||
|
paths=("$(pwd)")
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Find Git repositories
|
# Find Git repositories
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue