samba.sh fix #264, maybe?

This commit is contained in:
David Personette 2020-03-25 09:06:26 -04:00
parent 2016e1369d
commit 5f816df76a

View File

@ -75,6 +75,7 @@ perms() { local i file=/etc/samba/smb.conf
find $i -type f ! -perm 0664 -exec chmod 0664 {} \; find $i -type f ! -perm 0664 -exec chmod 0664 {} \;
done done
} }
export -f perms
### recycle: disable recycle bin ### recycle: disable recycle bin
# Arguments: # Arguments:
@ -257,7 +258,7 @@ done < <(env | awk '/^USER[0-9=_]/ {sub (/^[^=]*=/, "", $0); print}')
[[ "${WORKGROUP:-""}" ]] && workgroup "$WORKGROUP" [[ "${WORKGROUP:-""}" ]] && workgroup "$WORKGROUP"
[[ "${WIDELINKS:-""}" ]] && widelinks [[ "${WIDELINKS:-""}" ]] && widelinks
[[ "${INCLUDE:-""}" ]] && include "$INCLUDE" [[ "${INCLUDE:-""}" ]] && include "$INCLUDE"
[[ "${PERMISSIONS:-""}" ]] && perms [[ "${PERMISSIONS:-""}" ]] && perms &
if [[ $# -ge 1 && -x $(which $1 2>&-) ]]; then if [[ $# -ge 1 && -x $(which $1 2>&-) ]]; then
exec "$@" exec "$@"