openmamba-netsrpms: fix checks for existing package and update available

This commit is contained in:
Silvan Calarco 2014-07-24 13:33:12 +02:00
parent 17d323c6e2
commit e613b469ed

View File

@ -48,16 +48,16 @@ declare -A SRPMVERSION SRPMRELEASE
for pckname in $PACKAGES; do
icon=`grep Icon= /usr/share/applications/openmamba-$pckname.desktop | sed "s|Icon=||"`
SRPM_PATH=$DISTRO_SRPMS_DIR/${pckname}
SPEC_PATHNAME=$SRPM_PATH/${pckname}.spec
[ "$SPEC_PATHNAME" ] || {
[ -r "$SPEC_PATHNAME" ] || {
echo $"$me: $pckname is missing in $DISTRO_SRPMS_DIR; aborting."
exit 255
}
icon=`grep Icon= /usr/share/applications/openmamba-$pckname.desktop | sed "s|Icon=||"`
SPEC_VERSION=${SRPMVERSION[${pckname}]}-${SRPMRELEASE[${pckname}]}
RPM_INSTALLED=`rpm -q $pckname`
@ -78,7 +78,7 @@ for pckname in $PACKAGES; do
elif [ "$UPGRADE_MODE" ]; then
continue
fi
elif [ "$UPGRADE_MODE" ]; then
elif [ ! "$FORCE_MODE" ]; then
continue
fi