diff options
Diffstat (limited to 'db-remove')
-rwxr-xr-x | db-remove | 16 |
1 files changed, 8 insertions, 8 deletions
@@ -4,7 +4,7 @@ . "$(dirname "$(readlink -e "$0")")/db-functions" if [ $# -lt 3 ]; then - msg "usage: ${0##*/} <repo> <arch> <pkgname|pkgbase> ..." + msg "usage: %s <repo> <arch> <pkgname|pkgbase> ..." "${0##*/}" exit 1 fi @@ -12,8 +12,8 @@ repo="$1" arch="$2" pkgbases=("${@:3}") -if ! check_repo_permission $repo; then - die "You don't have permission to remove packages from ${repo}" +if ! check_repo_permission "$repo"; then + die "You don't have permission to remove packages from %s" "${repo}" fi if [ "$arch" == "any" ]; then @@ -23,19 +23,19 @@ else fi for tarch in "${tarches[@]}"; do - repo_lock $repo $tarch || exit 1 + repo_lock "$repo" "$tarch" || exit 1 done remove_pkgs=() for pkgbase in "${pkgbases[@]}"; do - msg "Removing $pkgbase from [$repo]..." + msg "Removing %s from [%s]..." "$pkgbase" "$repo" path="$(xbs releasepath "$pkgbase" "$repo" "$arch")" if [ -d "$path" ]; then eval "remove_pkgs+=($(. "$path/PKGBUILD"; printf '%q ' "${pkgname[@]}"))" xbs unrelease "$pkgbase" "$repo" "$arch" else - warning "$pkgbase not found in XBS $repo-$arch" - warning "Removing only $pkgbase from the repo" + warning "%s not found in XBS %s" "$pkgbase" "$repo-$arch" + warning "Removing only %s from the repo" "$pkgbase" warning "If it was a split package you have to remove the others yourself!" remove_pkgs+=("$pkgbase") fi @@ -43,5 +43,5 @@ done for tarch in "${tarches[@]}"; do arch_repo_remove "${repo}" "${tarch}" "${remove_pkgs[@]}" - repo_unlock $repo $tarch + repo_unlock "$repo" "$tarch" done |