PKGBUILDs/scripts/pkgverchecker
Mike Staszel 365cdd9a53 Sort
2010-10-07 16:49:21 -05:00

28 lines
885 B
Text
Executable file

# This is a simple package version checker (for now)
#
# So far it only lists the names and versions of packages in ABS.
# Planned is to grab repository pkgvers, then ABS vers, and only
# output the differences, i.e. what packages need to be upgraded.
ABSDIR=/build/abs
REPODIR=/build/packages
cd $ABSDIR/$1
echo "<h3>" ; echo $1 ; echo "</h3>"
echo ""
for i in `find . -maxdepth 1 -mindepth 1 -type d|sort`; do
cd $ABSDIR/$1/$i > /dev/null 2>&1
echo "<b>"
grep pkgname= PKGBUILD | sed -e 's/pkgname=//'
echo "</b>"
grep pkgver= PKGBUILD | sed -e 's/pkgver=//'
grep pkgrel= PKGBUILD | sed -e 's/pkgrel=/-/'
echo "</br>"
echo ""
done
echo "<br /><br /><h2>In Repository</h2>"
cd $REPODIR/$1
ls | sed 's#.pkg.tar.xz#<br />#' | sed '#s#.pkg.tar.gz#<br />#' | sed 's#core.db.tar.gz##' | sed 's#extra.db.tar.gz##' | sed 's#community.db.tar.gz##'