/[smeserver]/builds_bin/genpatches
ViewVC logotype

Diff of /builds_bin/genpatches

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

Revision 1.3 by slords, Sat Jul 26 21:51:02 2008 UTC Revision 1.7 by slords, Thu Mar 5 21:41:33 2009 UTC
# Line 26  do Line 26  do
26      # Build console files      # Build console files
27      pkgname=$(ls -d /etc/pootle/cvs/smeserver/smeserver-locale/*7/*/root | cut -d/ -f8)      pkgname=$(ls -d /etc/pootle/cvs/smeserver/smeserver-locale/*7/*/root | cut -d/ -f8)
28      mkdir -p ${pkgname}.update/po/$lang      mkdir -p ${pkgname}.update/po/$lang
29      for pkg in $(ls /etc/pootle/po/sme7bc/templates/ | sed -n '/^anaconda.pot$/b;s@\.pot@\.po@p')      for pkg in $(ls /etc/pootle/po/sme7bc/templates/ -I anaconda.pot | sed -n 's@\.pot@\.po@p')
30      do      do
31          msgcat -F --no-wrap /etc/pootle/po/sme7bc/$lang/$pkg \          msgcat -F --no-wrap /etc/pootle/po/sme7bc/$lang/$pkg \
32          | grep -v 'Project-Id-Version\|Report-Msgid-Bugs-To\|POT-Creation-Date\|PO-Revision-Date\|Last-Translator\|Language-Team\|X-Generator' \          | grep -v 'Project-Id-Version\|Report-Msgid-Bugs-To\|POT-Creation-Date\|PO-Revision-Date\|Last-Translator\|Language-Team\|X-Generator' \
33          | sed '0,/msgid ""/{/^#/d};/^#,/d' \          | sed '0,/msgid ""/{/^#/d};/^#,/d' \
34          > ${pkgname}.update/po/$lang/$pkg          > ${pkgname}.update/po/$lang/$pkg
35      done      done
36    
37        # Build sme7admin file
38        pkgname=$(ls -d /etc/pootle/cvs/smecontribs/smeserver-sme7admin/*7/*/root | cut -d/ -f8)
39        mkdir -p ${pkgname}.update/po/$lang
40        msgcat -F --no-wrap /etc/pootle/po/sme7cp/$lang/sme7admin.po \
41        | grep -v 'Project-Id-Version\|Report-Msgid-Bugs-To\|POT-Creation-Date\|PO-Revision-Date\|Last-Translator\|Language-Team\|X-Generator' \
42        | sed '0,/msgid ""/{/^#/d};/^#,/d' \
43        > ${pkgname}.update/po/$lang/sme7admin.po
44  done  done
45    
46  # Build translated xml files  # Build translated xml files
47  for pkg in $(ls /etc/pootle/po/sme7*p/templates/ | sed -n 's@\.pot@@p')  for pkg in $(ls /etc/pootle/po/sme7*p/templates/ -I sme7admin.pot | sed -n 's@\.pot@@p')
48  do  do
49      pkgname=$(find /etc/pootle/cvs/smecontribs/*/*7/*/root/etc/e-smith/locale/en-us -name $pkg | cut -d/ -f8)      pkgname=$(find /etc/pootle/cvs/smecontribs/*/*7/*/root/etc/e-smith/locale/en-us -name $pkg | cut -d/ -f8)
50      if [ -z "$pkgname" ]      if [ -z "$pkgname" ]
# Line 64  done Line 72  done
72  # Build xml diffs  # Build xml diffs
73  for pkg in $(ls -d *.update | sed 's@.update$@@')  for pkg in $(ls -d *.update | sed 's@.update$@@')
74  do  do
75        rm -f /var/www/html/patches/$(echo $pkg | sed 's/-[^-]\+$//')-*-locale-*.patch
76        [ -d $pkg.update/root/etc/e-smith/locale ] || continue
77      orig=/etc/pootle/cvs/sme*/*/*7/$pkg/root/etc/e-smith/locale      orig=/etc/pootle/cvs/sme*/*/*7/$pkg/root/etc/e-smith/locale
     rm /var/www/html/patches/$(echo $pkg | sed 's/-[^-]\+$//')-*-locale-*.patch  
78      diff -ruN $orig $pkg.update/root/etc/e-smith/locale \      diff -ruN $orig $pkg.update/root/etc/e-smith/locale \
79      | sed 's@^\(---\|+++\) [^ ]\+/\([^/]\+/root/.*\)@\1 \2@;/^diff -ruN/d' \      | sed 's@^\(---\|+++\) [^ ]\+/\([^/]\+/root/.*\)@\1 \2@;/^diff -ruN/d' \
80      > /var/www/html/patches/$pkg-locale-$(date +%F).patch      > /var/www/html/patches/$pkg-locale-$(date +%F).patch
# Line 74  done Line 83  done
83  # Build console diffs  # Build console diffs
84  pkg=$(ls -d smeserver-locale-* | sed 's@.update$@@')  pkg=$(ls -d smeserver-locale-* | sed 's@.update$@@')
85  orig=/etc/pootle/cvs/smeserver/smeserver-locale/*7/$pkg/po  orig=/etc/pootle/cvs/smeserver/smeserver-locale/*7/$pkg/po
86  rm /var/www/html/patches/$(echo $pkg | sed 's/-[^-]\+$//')-*-locale-*.patch  diff -ruN $orig $pkg.update/po \
87    | sed 's@^\(---\|+++\) [^ ]\+/\([^/]\+/po/.*\)@\1 \2@;/^diff -ruN/d' \
88    >> /var/www/html/patches/$pkg-locale-$(date +%F).patch
89    
90    # Build sme7admin diff
91    pkg=$(ls -d smeserver-sme7admin-* | sed 's@.update$@@')
92    orig=/etc/pootle/cvs/smecontribs/smeserver-sme7admin/*7/$pkg/po
93  diff -ruN $orig $pkg.update/po \  diff -ruN $orig $pkg.update/po \
94  | sed 's@^\(---\|+++\) [^ ]\+/\([^/]\+/po/.*\)@\1 \2@;/^diff -ruN/d' \  | sed 's@^\(---\|+++\) [^ ]\+/\([^/]\+/po/.*\)@\1 \2@;/^diff -ruN/d' \
95  >> /var/www/html/patches/$pkg-locale-$(date +%F).patch  >> /var/www/html/patches/$pkg-locale-$(date +%F).patch


Legend:
Removed lines/characters  
Changed lines/characters
  Added lines/characters

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed