autodist-upstream-updates: skip unstable updates

This commit is contained in:
Silvan Calarco 2013-02-02 14:05:36 +01:00
parent 8235cba011
commit c1285c09cf

View File

@ -186,7 +186,8 @@ while read line; do
alias=`grep "^$pkg" $ALIASES_DB`
[ "$alias" ] || alias=`grep "^lib$pkg " $ALIASES_DB`
[ "$alias" ] && pkg=$alias
line=`grep -i " $pkg[^-_A-Za-z0-9]" $buildstmp || grep -i " lib$pkg[^-_A-Za-z0-9]" $buildstmp`
line=`grep -i "^$pkg:" $buildstmp || grep -i "^lib$pkg:" $buildstmp`
# grep -i " $pkg[^-_A-Za-z0-9]" $buildstmp
if [ "$line" ]; then
pkg=${line/:*}
[ "$pkg" -a "$ver" ] && echo "$pkg $ver ${alias/* /}" >> $tmpfile
@ -250,6 +251,12 @@ rm -f $tmpfile
> $UPDATES_DB
unset lastpkg
while read pkg ver alias; do
# skip updates to unstable versions
unset found_beta
for b in alpha beta rc "~"; do
[ "${ver/$b}" != "${ver}" ] && found_beta=1
done
[ "$found_beta" ] && continue
if [ "$pkg" = "$lastpkg" ]; then
# echo "Warning: duplicate found: $pkg lastver: $lastver ver: $ver" >&2
version_find_bigger $lastver $ver