summarylogtreecommitdiffstats
path: root/fix-permissions.sh
blob: 8218c3b94d2cdc19a85bfcb7d8278fdba87fb8cf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
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 $_group /opt/jagged-alliance/{,sound.cfg,qickstrt.sav}
chmod g+w     /opt/jagged-alliance/{,sound.cfg,qickstrt.sav}