Sophie

Sophie

distrib > Mageia > 6 > x86_64 > by-pkgid > e2cfbfd071db1a591b9bff62905a3c1e > scriptlet

initscripts-9.55-24.mga6.x86_64.rpm

PREUN

/bin/sh
/usr/share/rpm-helper/del-service initscripts $1 netconsole 


/usr/share/rpm-helper/del-service initscripts $1 dm 


/usr/share/rpm-helper/del-service initscripts $1 network-up 


/usr/share/rpm-helper/del-service initscripts $1 network 


/usr/share/rpm-helper/del-service initscripts $1 partmon

POSTUN

/bin/sh
if [ -f /var/lock/TMP_1ST ];then 
		rm -f /var/lock/TMP_1ST
fi
if [ "$1" = "0" ]; then
	for i in /etc/locale/*/LC_MESSAGES/initscripts.mo
	do
		rm -f $i
		rmdir `dirname $i` >/dev/null 2> /dev/null
	done
	rmdir /etc/locale/* >/dev/null 2> /dev/null
fi

POSTTRANS

/bin/sh
/usr/bin/systemd-tmpfiles --create initscripts.conf 

##Fixme
touch /etc/sysconfig/i18n
##
touch /var/log/wtmp /var/log/btmp
chown root:utmp /var/log/wtmp /var/log/btmp
chmod 664 /var/log/wtmp
chmod 600 /var/log/btmp

if [ $1 = 1 ]; then /sbin/chkconfig --add partmon; fi;

if [ $1 = 1 ]; then /sbin/chkconfig --add network; fi;

if [ $1 = 1 ]; then /sbin/chkconfig --add network-up; fi;

if [ $1 = 1 ]; then /sbin/chkconfig --add netconsole; fi;

# /etc/sysconfig/desktop format has changed
if [ -r /etc/sysconfig/desktop ]; then
    if ! grep -q = /etc/sysconfig/desktop; then
        DESK=`cat /etc/sysconfig/desktop`
        echo "DESKTOP=$DESK" > /etc/sysconfig/desktop
    fi
fi

# Add right translation file
for i in `echo $LANGUAGE:$LC_ALL:$LC_COLLATE:$LANG:C | tr ':' ' '`
do
	if [ -r /usr/share/locale/$i/LC_MESSAGES/initscripts.mo ]; then
		mkdir -p /etc/locale/$i/LC_MESSAGES/
		cp /usr/share/locale/$i/LC_MESSAGES/initscripts.mo \
			/etc/locale/$i/LC_MESSAGES/
                #
		# warly
		# FIXME: this should be done by each locale when installed or upgraded
		#
		pushd /usr/share/locale/$i/ > /dev/null && for j in LC_*
		do
			if [ -r $j -a ! -d $j ]; then
			    cp $j /etc/locale/$i/
			fi
		done && popd > /dev/null
		if [ -r /usr/share/locale/$i/LC_MESSAGES/SYS_LC_MESSAGES ]; then
			cp /usr/share/locale/$LANG/LC_MESSAGES/SYS_LC_MESSAGES /etc/locale/$i/LC_MESSAGES/
		fi
		#
		#
		break
	fi
done


# only needed on upgrade
if [ $1 != 0 ]; then
	# Handle boot sequence changes on upgrade
	if [[ -f /etc/rc3.d/S80partmon ]] && [[ -f /etc/rc5.d/S80partmon ]] && egrep -q 'chkconfig: [0-9]+ 13' /etc/init.d/partmon; then chkconfig --add partmon || : ; fi; 

fi