diff options
author | Constantin Nickel | 2016-11-19 09:01:57 +0100 |
---|---|---|
committer | Constantin Nickel | 2016-11-19 09:01:57 +0100 |
commit | 581dfe0f4c720ef984b6160428cc4ed3e73c9ef2 (patch) | |
tree | 86b578d4d275fa72b4c2a28a38c92f69e0378e70 /fix-permissions.sh | |
download | aur-581dfe0f4c720ef984b6160428cc4ed3e73c9ef2.tar.gz |
initial commit
Diffstat (limited to 'fix-permissions.sh')
-rw-r--r-- | fix-permissions.sh | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/fix-permissions.sh b/fix-permissions.sh new file mode 100644 index 000000000000..c7020157716d --- /dev/null +++ b/fix-permissions.sh @@ -0,0 +1,15 @@ +#!/usr/bin/sh + +_group="${1:-games}" + +getent group $_group &> /dev/null + +if [ $? != 0 ]; then + echo "group '$_group' not found"; + echo "${0##/} [group] default: games" + exit 1 +fi + +# fix permissions +chgrp -R $_group /opt/syndicate-plus/{synd,syndicat/data,datadisk/data} +chmod -R g+w /opt/syndicate-plus/{synd,syndicat/data,datadisk/data} |