Fix package version check on checkapk

The assignment of the oldpkg variable is missing the name of the package
This commit is contained in:
Leo 2019-09-03 05:12:02 -03:00 committed by Natanael Copa
parent 05eee44039
commit 1c075c2855

View File

@ -67,7 +67,7 @@ for i in $pkgname $subpackages; do
# generate a temp repositories file with only the http(s) repos
grep -E "^https?:" /etc/apk/repositories > $tmpdir/repositories
oldpkg=$(apk fetch --repositories-file $tmpdir/repositories --simulate 2>&1 | sed 's/^Downloading //')
oldpkg=$(apk fetch --repositories-file $tmpdir/repositories --simulate $_pkgname 2>&1 | sed 's/^Downloading //')
if [ "${oldpkg}" = "${pkg}" ]; then
die "the built package ($_pkgname) is already in the repo"
fi