aboutsummaryrefslogtreecommitdiffstats
path: root/approve.sh
diff options
context:
space:
mode:
authorMarcelo Leitner <mrl@mandriva.com>2007-03-23 13:14:47 +0000
committerMarcelo Leitner <mrl@mandriva.com>2007-03-23 13:14:47 +0000
commit9f069679e6b24ebe7409414a9ca2cc2e75fe05ea (patch)
tree02e12297c5f654a7c3d2edf407249da29cfc61b2 /approve.sh
parente9c6a00090a14131c46e52414906c3d6dc3a15f6 (diff)
downloadiurt-9f069679e6b24ebe7409414a9ca2cc2e75fe05ea.tar
iurt-9f069679e6b24ebe7409414a9ca2cc2e75fe05ea.tar.gz
iurt-9f069679e6b24ebe7409414a9ca2cc2e75fe05ea.tar.bz2
iurt-9f069679e6b24ebe7409414a9ca2cc2e75fe05ea.tar.xz
iurt-9f069679e6b24ebe7409414a9ca2cc2e75fe05ea.zip
- Fix updates handling: updates is not a repository, it's a media. The
repository should be kept.
Diffstat (limited to 'approve.sh')
-rwxr-xr-xapprove.sh9
1 files changed, 4 insertions, 5 deletions
diff --git a/approve.sh b/approve.sh
index 7de0084..8358965 100755
--- a/approve.sh
+++ b/approve.sh
@@ -6,7 +6,6 @@ DESTBASEDIR=/home/mandrake/uploads/approved
REJECTEDDIR=/home/mandrake/uploads/rejected
LATERBASEDIR=/home/mandrake/uploads/later
DISTRO=cooker
-UPDATEDISTRO="2007.1"
function list() {
echo "The following packages are currently queued:" >&2
@@ -42,7 +41,7 @@ function list_approved() {
# $1 = id = package id
# $2 = dest = destination queue
-# $3 = media = forced distro/media, like "2007.1/updates/release/"
+# $3 = media = forced media, like "updates/"
function move() {
id="$1"
dest="$2"
@@ -61,9 +60,9 @@ function move() {
for srcpath in $packages; do
destpath=$(echo "$srcpath" | sed "s@$SRCBASEDIR@$dest@")
if [ -n "$media" ]; then
- destpath=$(echo "$destpath" | sed "s@\($dest\)/\(\([^/]\+/\)\{3\}\)@\1/$media@")
+ destpath=$(echo "$destpath" | sed "s@\($dest\)/\(\([^/]\+/\)\{2\}\)\([^/]\+/\)@\1/\2$media@")
fi
- mv "$srcpath" "$destpath"
+ mv "$srcpath" "$destpath"
done
echo "done."
}
@@ -97,7 +96,7 @@ elif [ "$1" == "--approve" ]; then
done
elif [ "$1" == "--updates" ]; then
while [ -n "$2" ]; do
- move "$2" "$DESTBASEDIR" "$UPDATEDISTRO/updates/release/"
+ move "$2" "$DESTBASEDIR" "updates/"
shift
done
elif [ "$1" == "--later" ]; then