From 0be51cb3e78592984ea8152cac176448d1765fb0 Mon Sep 17 00:00:00 2001 From: Luke Shumaker Date: Sun, 24 May 2015 12:35:53 -0600 Subject: db-remove: pull the path ${SVNREPO}/$repo/$pkgbase into a variable. This way, if it changes, it only needs to be changed in one place. --- db-remove | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'db-remove') diff --git a/db-remove b/db-remove index 2f18ff7..53fdb2a 100755 --- a/db-remove +++ b/db-remove @@ -30,8 +30,9 @@ remove_pkgs=() for pkgbase in "${pkgbases[@]}"; do msg "Removing %s from [%s]..." "$pkgbase" "$repo" - if [ -d "${SVNREPO}/$repo/$pkgbase" ]; then - remove_pkgs+=($(. "${SVNREPO}/$repo/$pkgbase/PKGBUILD"; echo "${pkgname[@]}")) + path="${SVNREPO}/$repo/$pkgbase" + if [ -d "$path" ]; then + remove_pkgs+=($(. "$path/PKGBUILD"; echo "${pkgname[@]}")) else warning "%s not found in ABS(libre)" "$pkgbase" warning "Removing only %s from the repo" "$pkgbase" -- cgit v1.2.3