Don't like ads? PRO users don't see any ads ;-)
Guest

Untitled

By: a guest on Apr 17th, 2012  |  syntax: None  |  size: 1.14 KB  |  hits: 12  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. Index: x-test/internal/update_xx.sh
  2. ===================================================================
  3. --- x-test/internal/update_xx.sh        (revision 1113684)
  4. +++ x-test/internal/update_xx.sh        (working copy)
  5. @@ -9,7 +9,7 @@
  6.  fi
  7.  xx=x-test
  8.  for i in $list; do
  9. -    test -z "VERBOSE" || echo "# templates/$i"
  10. +    test -z "$VERBOSE" || echo "# templates/$i"
  11.      tmpdest=$xx/`echo $i | sed -e "s/\.pot/.tmp/"`
  12.      destdir=`dirname $tmpdest`
  13.      test -d $destdir || svn mkdir $destdir
  14. @@ -26,7 +26,12 @@
  15.      fi
  16.  
  17.      ### TODO: is this msgmerge still useful with transxx.py ?
  18. -    if ! msgmerge --no-fuzzy-matching -o $tmpdest $tmpdest templates/$i; then
  19. +    output=`msgmerge --no-fuzzy-matching -o $tmpdest $tmpdest templates/$i &> /tmp/updatextest`
  20. +    result=$?
  21. +    if [ -n "$VERBOSE" ]; then
  22. +        cat /tmp/updatextestresult
  23. +    fi
  24. +    if [ $result != 0 ] ; then
  25.          echo "Merging failed for $dest"
  26.          # keep the wrong data around, to be able to debug transxx.py
  27.          mv $tmpdest $dest.broken
  28. @@ -42,5 +47,6 @@
  29.      else
  30.          mv $tmpdest $dest
  31.      fi
  32. +    rm -f /tmp/updatextestresult
  33.  done