Sophie

Sophie

distrib > Mandriva > 7.2 > i586 > media > main > by-pkgid > a7931c2ee831f47ffffc11626cee3d88 > scriptlet

cups-drivers-0.3.6-30mdk.i586.rpm

POSTIN

/bin/sh

# Restart the CUPS daemon to refresh the database
! ( lpstat -r 1> /dev/null 2>&1 ) || (
  /etc/rc.d/init.d/cups stop 1> /dev/null 2>&1
  rm -f /etc/cups/ppds.dat
  rm -f /var/spool/cups/[cd]*
  rm -f /var/spool/cups/tmp/*
  /etc/rc.d/init.d/cups start 1> /dev/null 2>&1
)

##menu
if [ -x /usr/bin/update-menus ]; then
        /usr/bin/update-menus
fi

POSTUN

/bin/sh

if [ "$1" = 0 ]; then

	# Restart the CUPS daemon to refresh the database
	! ( lpstat -r 1> /dev/null 2>&1 ) || (
	    /etc/rc.d/init.d/cups stop 1> /dev/null 2>&1
	    rm -f /etc/cups/ppds.dat
	    rm -f /var/spool/cups/[cd]*
	    rm -f /var/spool/cups/tmp/*
	    /etc/rc.d/init.d/cups start 1> /dev/null 2>&1
	)
 
	## menu
	if [ -x /usr/bin/update-menus ]; then
                /usr/bin/update-menus
        fi
fi