Fix for issue #128
This commit is contained in:
parent
dcdc081f30
commit
7a84fbdfa8
2 changed files with 12 additions and 5 deletions
|
|
@ -208,6 +208,9 @@ INCLIST=( "/home/foobar_user_name/Documents/" )
|
|||
# "/**Icon?" \
|
||||
# "/**.AppleDouble" \
|
||||
# )
|
||||
#
|
||||
# If you don't want to exclude anything, use EXCLIST=()
|
||||
#
|
||||
# Simpler example with one location. Adapt it to your needs.
|
||||
|
||||
EXCLIST=( "/home/foobar_user_name/Documents/foobar-to-exclude" )
|
||||
|
|
|
|||
|
|
@ -553,7 +553,7 @@ include_exclude()
|
|||
OLDIFS=$IFS
|
||||
IFS=$(echo -en "\t\n")
|
||||
|
||||
# Exlcude device files?
|
||||
# Exclude device files?
|
||||
if [ ! -z "${EXDEVICEFILES}" ] && [ "${EXDEVICEFILES}" -ne 0 ]; then
|
||||
TMP=" --exclude-device-files"
|
||||
EXCLUDE=${EXCLUDE}${TMP}
|
||||
|
|
@ -561,14 +561,18 @@ include_exclude()
|
|||
|
||||
for include in "${INCLIST[@]}"
|
||||
do
|
||||
TMP=" --include='$include'"
|
||||
INCLUDE=${INCLUDE}${TMP}
|
||||
if [[ -n "$include" ]]; then
|
||||
TMP=" --include='$include'"
|
||||
INCLUDE=${INCLUDE}${TMP}
|
||||
fi
|
||||
done
|
||||
|
||||
for exclude in "${EXCLIST[@]}"
|
||||
do
|
||||
TMP=" --exclude '$exclude'"
|
||||
EXCLUDE=${EXCLUDE}${TMP}
|
||||
if [[ -n "$exclude" ]]; then
|
||||
TMP=" --exclude '$exclude'"
|
||||
EXCLUDE=${EXCLUDE}${TMP}
|
||||
fi
|
||||
done
|
||||
|
||||
# Include/Exclude globbing filelist
|
||||
|
|
|
|||
Loading…
Reference in a new issue