summaryrefslogtreecommitdiff
path: root/src/toru
diff options
context:
space:
mode:
Diffstat (limited to 'src/toru')
-rwxr-xr-xsrc/toru/toru-info7
-rwxr-xr-xsrc/toru/toru-path4
2 files changed, 3 insertions, 8 deletions
diff --git a/src/toru/toru-info b/src/toru/toru-info
index 5b6fd01..6418de4 100755
--- a/src/toru/toru-info
+++ b/src/toru/toru-info
@@ -1,12 +1,13 @@
#!/bin/bash
# Prints info about a given pkgname
. libremessages
+. $(librelib conf)
for _pkg in $@; do
_pkgbuild="$(toru-where $_pkg)"
if [ -f "$_pkgbuild/PKGBUILD" ]; then
- source "$_pkgbuild/PKGBUILD" 2>/dev/null || {
+ load_PKGBUILD "$_pkgbuild/PKGBUILD" 2>/dev/null || {
warning "Errors on %s" $_pkg
continue
}
@@ -14,8 +15,6 @@ for _pkg in $@; do
deps="${depends[@]} ${makedepends[@]} ${checkdepends[@]}"
repo="$(basename $(dirname "$_pkgbuild"))"
- unset build package depends makedepends checkdepends optdepends source md5sums
-
msg "%s/%s %s-%s" $repo $_pkg $pkgver $pkgrel
msg2 "$pkgdesc"
msg2 "$url"
@@ -23,6 +22,4 @@ for _pkg in $@; do
else
warning "%s doesn't exist" $_pkg
fi
-
- unset pkgname pkgver pkgrel pkgdesc url
done
diff --git a/src/toru/toru-path b/src/toru/toru-path
index 3f35dbe..ca87e48 100755
--- a/src/toru/toru-path
+++ b/src/toru/toru-path
@@ -32,7 +32,7 @@ msg "Updating path cache"
msg2 "${#pkgbuilds[@]} PKGBUILDs to update"
for _pkgbuild in ${pkgbuilds[@]}; do
# plain "$_pkgbuild"
- source ${_pkgbuild} >/dev/null 2>&1 || {
+ load_PKGBUILD "${_pkgbuild}" >/dev/null 2>&1 || {
error "${_pkgbuild} contains errors, skipping"
continue
}
@@ -43,8 +43,6 @@ for _pkgbuild in ${pkgbuilds[@]}; do
$VERBOSE && msg2 "${_pkg} -> ${fullpath}"
tcamgr put ${PATHFILE} ${_pkg/[<>=]*} ${fullpath}
done
-
- unset pkgbase pkgname provides
done
lastsync ${LASTSYNCFILE}