Sophie

Sophie

distrib > Mandriva > current > i586 > media > main-updates > by-pkgid > 7b2fcc2a66218536d2163e053e644261 > scriptlet

openoffice.org-wiki-publisher-3.2.1-0.3mdv2010.2.i586.rpm

PREUN

/bin/sh
if [ $1 -eq 0 ];then
	idextension=$(/usr/bin/unopkg list --shared 2> /dev/null | sed -ne 's/^Identifier: \(com.sun.wiki-publisher\)/\1/p');
	if [ "z$idextension" != "z" ]; then
		/usr/bin/unopkg remove --shared $idextension 2> /dev/null
		/usr/bin/unopkg list --shared &> /dev/null
	fi
fi

POSTIN

/bin/sh
# upgrade 
if [ $1 -ge 2 ];then
	idextension=$(/usr/bin/unopkg list --shared 2> /dev/null | sed -ne 's/^Identifier: \(com.sun.wiki-publisher\)/\1/p');
	if [ "z$idextension" != "z" ]; then
		/usr/bin/unopkg remove --shared $idextension 2> /dev/null
		/usr/bin/unopkg list --shared &> /dev/null
	fi
fi	
#install 
/usr/bin/unopkg add --shared /usr/lib/ooo/extensions/wiki-publisher.oxt 2> /dev/null
/usr/bin/unopkg list --shared &> /dev/null