summaryrefslogtreecommitdiffstats
path: root/checkpkg.in
diff options
context:
space:
mode:
Diffstat (limited to 'checkpkg.in')
-rw-r--r--checkpkg.in7
1 files changed, 2 insertions, 5 deletions
diff --git a/checkpkg.in b/checkpkg.in
index ec58ff6..03e29f7 100644
--- a/checkpkg.in
+++ b/checkpkg.in
@@ -24,7 +24,7 @@ if [[ ! -f PKGBUILD ]]; then
fi
. ./PKGBUILD
-if [[ $arch == 'any' ]]; then
+if [[ ${arch[0]} == 'any' ]]; then
CARCH='any'
fi
@@ -39,11 +39,8 @@ for _pkgname in "${pkgname[@]}"; do
ln -s "$pkgfile" "$TEMPDIR"
- pkgurl=$(pacman -Spdd --print-format '%l' --noconfirm "$_pkgname")
-
- if [[ $? -ne 0 ]]; then
+ pkgurl=$(pacman -Spdd --print-format '%l' --noconfirm "$_pkgname") ||
die "Couldn't download previous package for %s." "$_pkgname"
- fi
oldpkg=${pkgurl##*://*/}