You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Kelly (KT) Thompson edited this page Dec 9, 2019
·
1 revision
Summary
I use this small bit of code at the top of many shell scripts to ensure any artifacts generated by the script have the desired permissions.
# execute the remainder of this script as group 'foo'if [[ $(id -gn)!= foo ]];thenexec sg foo "$0$*"fi# Full access for _User_, Read and Execute for _Group_, No access for _World_.umask 0027