set -e
USERNAME=''
-[ -r /etc/grml/grml-live.conf ] && . /etc/grml/grml-live.conf
+[ -r /etc/grml/grml-live.conf ] && . /etc/grml/grml-live.conf
+[ -r /etc/grml/grml-live.local ] && . /etc/grml/grml-live.local
[ -n "$USERNAME" ] || USERNAME=grml
if grep -q "$USERNAME:x:1000" $target/etc/group ; then
add_user_to_group() {
[ -n "$1" ] || return 1
if grep -q $1 $target/etc/group ; then
- grep "$1:x:.*$USERNAME" $target/etc/group || addgroup $1 $USERNAME
+ grep "$1:x:.*$USERNAME" $target/etc/group || $ROOTCMD addgroup $USERNAME $1
fi
}