[DRE-commits] [SCM] pkg-ruby-extras.git branch, master, updated. 04df8a542a071df25c80800157cf2914828c3196

Antonio Terceiro terceiro at debian.org
Sat Jan 28 13:00:35 UTC 2012


The following commit has been merged in the master branch:
commit 04df8a542a071df25c80800157cf2914828c3196
Author: Antonio Terceiro <terceiro at debian.org>
Date:   Sat Jan 28 10:58:42 2012 -0200

    encancements to quick-update script

diff --git a/quick-update b/quick-update
index 8768655..87eee3b 100755
--- a/quick-update
+++ b/quick-update
@@ -9,42 +9,34 @@ for package in $packages; do
     echo -n \"\$package \"
     cat \$package/.git/refs/heads/master
   )
-done
+done 2>/dev/null
 "
 remote_list_heads=$(echo "$list_heads" | sed -e 's/\/\.git/.git/g')
 
-echo "Listing remote master branches ..."
+echo "I: Listing remote master branches ..."
 ssh git.debian.org "cd /git/pkg-ruby-extras/ && $remote_list_heads" > remote.heads
 
-echo "Listing local master branches ..."
+echo "I: Listing local master branches ..."
 sh -c "$list_heads" > local.heads
 
 need_push=""
 need_pull=""
-diff remote.heads local.heads | grep '^<' | cut -d ' ' -f 2-3 | while read package read; do
-  for package in $diff; do
-    if (cd $package && git show $head >/dev/null 2>&1); then
-      need_push="$need_push $package"
-    else
-      need_pull="$need_pull $package"
-    fi
-  done
+diff remote.heads local.heads | grep '^<' | cut -d ' ' -f 2-3 | while read package head; do
+  if (cd $package && git show $head >/dev/null 2>&1); then
+    echo "\033[01;33mW: $package needs to be pushed!\033[m"
+    need_push="$need_push $package"
+  else
+    need_pull="$need_pull $package"
+  fi
 done
 
-if [ -n "$need_push" ]; then
-  for package in $need_push; do
-    echo "W: Package $package needs to be pushed!"
-  done
-fi
-
 if [ -n "$need_pull" ]; then
-  echo "Packages that need to be pulled: $need_pull"
   for package in $need_pull; do
-    echo "Updating $package ..."
+    echo "I: Updating $package ..."
     (cd $package && git pull)
   done
 fi
 
-echo "Cloning new packages.."
+echo "I: Cloning new packages.."
 mr checkout
 

-- 
pkg-ruby-extras.git



More information about the Pkg-ruby-extras-commits mailing list