summaryrefslogtreecommitdiff
path: root/db-remove
diff options
context:
space:
mode:
authorLuke Shumaker <LukeShu@sbcglobal.net>2014-06-18 20:33:06 -0400
committerLuke Shumaker <lukeshu@sbcglobal.net>2016-04-16 13:51:18 -0400
commit6638878c5eb6d5116580d06cc3042a5e9beacb7e (patch)
tree92476d6e2ec6fada6b6e3bedb1cfcffcc7988065 /db-remove
parent7850874b1ef1b18de585be108e3be899d95a3a2a (diff)
Use printf-formatters instead of string interpolation on msg, error, etc.
Diffstat (limited to 'db-remove')
-rwxr-xr-xdb-remove10
1 files changed, 5 insertions, 5 deletions
diff --git a/db-remove b/db-remove
index f23cd9e..3bb67b0 100755
--- a/db-remove
+++ b/db-remove
@@ -4,7 +4,7 @@
. "$(dirname "$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
@@ -16,7 +16,7 @@ ftppath="$FTP_BASE/$repo/os"
svnrepo="$repo-$arch"
if ! check_repo_permission "$repo"; then
- die "You don't have permission to remove packages from ${repo}"
+ die "You don't have permission to remove packages from %s" "${repo}"
fi
if [ "$arch" == "any" ]; then
@@ -31,7 +31,7 @@ done
remove_pkgs=()
for pkgbase in "${pkgbases[@]}"; do
- msg "Removing $pkgbase from [$repo]..."
+ msg "Removing %s from [%s]..." "$pkgbase" "$repo"
arch_svn checkout -q "${SVNREPO}/${pkgbase}" "${WORKDIR}/svn/${pkgbase}" >/dev/null
if [ -d "${WORKDIR}/svn/$pkgbase/repos/$svnrepo" ]; then
@@ -39,8 +39,8 @@ for pkgbase in "${pkgbases[@]}"; do
arch_svn rm --force -q "${WORKDIR}/svn/$pkgbase/repos/$svnrepo"
arch_svn commit -q "${WORKDIR}/svn/$pkgbase" -m "${0##*/}: $pkgbase removed by $(id -un)"
else
- warning "$pkgbase not found in $svnrepo"
- warning "Removing only $pkgbase from the repo"
+ warning "%s not found in %s" "$pkgbase" "$svnrepo"
+ warning "Removing only %s from the repo" "$pkgbase"
warning "If it was a split package you have to remove the others yourself!"
remove_pkgs[${#remove_pkgs[*]}]=$pkgbase
fi