changeset 421:fb25f7a96b44

Partially merge 'hgsyncew' and 'hgsyncee'.
author Oleksandr Gavenko <gavenkoa@gmail.com>
date Thu, 13 Oct 2011 21:42:18 +0300
parents 7da781789a26
children 895cdda47780
files hg/hgsyncee hg/hgsyncew
diffstat 2 files changed, 8 insertions(+), 13 deletions(-) [+]
line wrap: on
line diff
--- a/hg/hgsyncee	Thu Oct 13 21:20:04 2011 +0300
+++ b/hg/hgsyncee	Thu Oct 13 21:42:18 2011 +0300
@@ -177,13 +177,12 @@
 
 echo
 
-for dir in `echo *`; do
-    [ -d $dir ] || continue
-    dir=${dir##*/}
+for dir in */.hg/.; do
+    dir=${dir%/.hg/.}
+
     MSG="'$dir' repo."
     PrintLog PROCESSING
 
-    # Заполняем HG_PULL_DIR новыми changeset из эталонного и промежуточного репозиториев.
     if [ -d $HG_PUSH_DIR/$dir ]; then
         if [ -d $HG_PULL_DIR/$dir ] ; then
             if CheckRepCompatibility $HG_PULL_DIR/$dir $HG_PUSH_DIR/$dir; then :
@@ -198,13 +197,13 @@
         fi
         if CheckRepCompatibility $HG_PULL_DIR/$dir ./$dir; then :
         else
-            MSG="It seems repo $dir and $HG_PULL_DIR/$dir not compatable."
+            MSG="It seems repo '$dir' and etalon repo not compatable."
             PrintLog
             exit 1;
         fi
         hg -R $HG_PULL_DIR/$dir pull ./$dir >>$LOG_FILE 2>&1
     else
-        MSG="'$dir' repo skiped. It is not found in etalon repo set."
+        MSG="'$dir' repo skiped. It is absent in etalon repo set."
         PrintLog INFO
         continue
     fi
--- a/hg/hgsyncew	Thu Oct 13 21:20:04 2011 +0300
+++ b/hg/hgsyncew	Thu Oct 13 21:42:18 2011 +0300
@@ -166,12 +166,8 @@
 
 echo
 
-for dir in `echo *`; do
-    [ -d $dir ] || continue
-    dir=${dir##*/}
-
-    # Проверяем корректность репозиториев.
-    [ -d $dir/.hg ] || continue
+for dir in */.hg/.; do
+    dir=${dir%/.hg/.}
 
     MSG="'$dir' repo."
     PrintLog PROCESSING
@@ -184,7 +180,7 @@
             exit 1;
         fi
     else
-        MSG="'$dir' repo skiped. It not found in etalon repo set."
+        MSG="'$dir' repo skiped. It is absent in etalon repo set."
         PrintLog INFO
         continue
     fi