summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAaron Griffin <aaronmgriffin@gmail.com>2009-07-20 13:28:06 -0700
committerAaron Griffin <aaronmgriffin@gmail.com>2009-07-20 13:28:06 -0700
commit9316686c4c29f92a9723d47f5137e172dea04441 (patch)
tree3c9269797fc94c64f8f39a43f2e0589f16984fa2
parentce9a9b1951cefbdf6b2df93b07eb9120295bec7a (diff)
ftpdir-cleanup: Corrections for 'any' packages
Signed-off-by: Aaron Griffin <aaronmgriffin@gmail.com>
-rwxr-xr-xmisc-scripts/ftpdir-cleanup6
1 files changed, 4 insertions, 2 deletions
diff --git a/misc-scripts/ftpdir-cleanup b/misc-scripts/ftpdir-cleanup
index fd771e7..9bac030 100755
--- a/misc-scripts/ftpdir-cleanup
+++ b/misc-scripts/ftpdir-cleanup
@@ -32,6 +32,7 @@ getpkgname() {
tmp=${1##*/}
tmp=${tmp%$PKGEXT}
tmp=${tmp%-$arch}
+ tmp=${tmp%-any}
echo ${tmp%-*-*}
}
@@ -40,7 +41,8 @@ getpkgname_ver() {
tmp=${1##*/}
tmp=${tmp%$PKGEXT}
- echo ${tmp%-$arch}
+ tmp=${tmp%-$arch}
+ echo ${tmp%-any}
}
MISSINGFILES=""
@@ -56,7 +58,7 @@ for pkg in *; do
filename=$(grep -A1 '^%FILENAME%$' "${pkg}/desc" | tail -n1)
[ -z "${filename}" ] && filename="${pkg}${PKGEXT}"
- if [ ! -f "${ftppath}/${filename}" ]; then
+ if [ ! -e "${ftppath}/${filename}" ]; then
MISSINGFILES="${MISSINGFILES} ${filename}"
else
pkgname="$(getpkgname ${filename})"