diff options
author | Constantin Nickel | 2016-11-20 14:21:53 +0100 |
---|---|---|
committer | Constantin Nickel | 2016-11-20 14:21:53 +0100 |
commit | c4e3c7ec80b5cd910b8047d3a849347ba8ecf716 (patch) | |
tree | 331e7078481888425dd7ed0974bff9fdebf2087b /fix-permissions.sh | |
download | aur-c4e3c7ec80b5cd910b8047d3a849347ba8ecf716.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..8730c5ddca89 --- /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/constructor/{savegame,settings/setsnd.cfg,settings/system.ini} +chmod -R g+w /opt/constructor/{savegame,settings/setsnd.cfg,settings/system.ini} |