Sophie

Sophie

distrib > Mageia > 1 > i586 > by-pkgid > 8554f30bf584832bbbca193fe01396ff > scriptlet

setup-2.7.18-3.mga1.i586.rpm

PREIN

/bin/sh
# due to important new group additions, we need to add them manually here if they
# don't already exist because rpm will create group.rpmnew instead
if [ -f /etc/group ]; then
    grep -q '^auth:' /etc/group || /usr/share/rpm-helper/add-group setup $1 auth  
    # be a little fancy here in case this is an upgrade and the user hasn't migrated to tcb yet
    if [ "`grep -q '^shadow:' /etc/group; echo $?`" == 1 ]; then
        /usr/share/rpm-helper/add-group setup $1 shadow  
        if [ -f /etc/shadow ]; then
            chmod 0440 /etc/shadow && chgrp shadow /etc/shadow
        fi
    fi
    grep -q '^chkpwd:' /etc/group || /usr/share/rpm-helper/add-group setup $1 chkpwd  
    grep -q '^dialout:' /etc/group || /usr/share/rpm-helper/add-group setup $1 dialout  
fi

POSTTRANS

/bin/sh
pwconv 2>/dev/null >/dev/null  || :
grpconv 2>/dev/null >/dev/null  || :

[ -f /var/log/lastlog ] || echo -n '' > /var/log/lastlog
[ -f /etc/mtab ] || echo -n '' > /etc/mtab

if [ -x /usr/sbin/nscd ]; then
	nscd -i passwd -i group || :
fi

Triggers

setup < 2.7.8

/bin/sh
# the files is no more in setup starting from 2.7.8, it is now in nfs-utils
if [ -e /etc/exports.rpmsave ]; then
  mv -f /etc/exports.rpmsave /etc/exports && echo "warning: /etc/exports.rpmsave restored as /etc/exports"
fi