From 0f1955c3f5f5868a13f1fe19eb2ce0baf3fc7852 Mon Sep 17 00:00:00 2001 From: Pascal Terjan Date: Sun, 22 Mar 2015 00:10:51 +0000 Subject: Speedup on cauldron by not running rpm -qp on all binary RPMS --- mga-move-pkg | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/mga-move-pkg b/mga-move-pkg index 120bb81..a3016ba 100755 --- a/mga-move-pkg +++ b/mga-move-pkg @@ -187,12 +187,9 @@ function movepkg() local file local srpm - for file in "$srcdir/"*.rpm; do - srpm=$(rpm -qp --qf '%{SOURCERPM}' "$file") - if [ "$srpm" = "$srcpkg" ]; then - echo " $(basename $file)" | tee -a "$_mailcontent" - $dryrun mv -v -f "$file" "$destdir" >>"$_mailcommands" 2>&1 - fi + for file in $(urpmf --synthesis "${srcdir}/media_info/synthesis.hdlist.cz" --qf '%filename:%sourcerpm' ":$srcpkg$" | cut -d: -f1); do + echo " $file" | tee -a "$_mailcontent" + $dryrun mv -v -f "$srcdir/$file" "$destdir" >>"$_mailcommands" 2>&1 done } -- cgit v1.2.1