13 |
|
|
14 |
# Update/expand smeserver cvs |
# Update/expand smeserver cvs |
15 |
cd /etc/pootle/cvs/smeserver |
cd /etc/pootle/cvs/smeserver |
16 |
for pkg in */sme7 anaconda/sme8 |
for pkg in */sme7 anaconda/sme8 booty/sme8 |
17 |
do |
do |
18 |
make -C $pkg clean &> /dev/null |
make -C $pkg clean &> /dev/null |
19 |
done |
done |
20 |
cvs update -dPA > /dev/null |
cvs update -dPA > /dev/null |
21 |
for pkg in */sme7 anaconda/sme8 |
for pkg in */sme7 anaconda/sme8 booty/sme8 |
22 |
do |
do |
23 |
make -C $pkg prep &> /dev/null |
make -C $pkg prep &> /dev/null |
24 |
done |
done |
83 |
# Apply templates to languages |
# Apply templates to languages |
84 |
for lang in $(ls -I templates /etc/pootle/po/sme* | grep '[[:alpha:]]$' | sort -u) |
for lang in $(ls -I templates /etc/pootle/po/sme* | grep '[[:alpha:]]$' | sort -u) |
85 |
do |
do |
|
# Create error compendium to assist translators |
|
|
pocompendium -e errors-$lang.po -d /etc/pootle/po/sme*/$lang |
|
|
sed -i '0,/^$/d;/^#~/d' errors-$lang.po |
|
|
sed -i ':a;/^\n*$/{$d;N;ba;}' errors-$lang.po |
|
|
chmod 644 errors-$lang.po |
|
|
diffmv errors-$lang.po /var/www/html/errors/errors-$lang.po |
|
|
|
|
86 |
# Create compendium to assist translations |
# Create compendium to assist translations |
87 |
pocompendium -c /etc/pootle/tmp/compendium-$lang.po -d /etc/pootle/po/*/$lang |
pocompendium -c /etc/pootle/tmp/compendium-$lang.po -d /etc/pootle/po/*/$lang |
88 |
|
|
112 |
diffmv $chk $(echo $chk | sed 's@/tmp/@/po/@') |
diffmv $chk $(echo $chk | sed 's@/tmp/@/po/@') |
113 |
done |
done |
114 |
|
|
115 |
|
# Create error compendium to assist translators |
116 |
|
for lang in $(ls -I templates /etc/pootle/po/sme* | grep '[[:alpha:]]$' | sort -u) |
117 |
|
do |
118 |
|
pocompendium -e errors-$lang.po -d /etc/pootle/po/sme*/$lang |
119 |
|
sed -i '0,/^$/d;/^#~/d' errors-$lang.po |
120 |
|
sed -i ':a;/^\n*$/{$d;N;ba;}' errors-$lang.po |
121 |
|
chmod 644 errors-$lang.po |
122 |
|
diffmv errors-$lang.po /var/www/html/errors/errors-$lang.po |
123 |
|
done |
124 |
|
|
125 |
#========================================================== |
#========================================================== |
126 |
|
|
127 |
# Recalculate stats and restart server |
# Recalculate stats and restart server |
194 |
# Build xml diffs |
# Build xml diffs |
195 |
for pkg in $(ls -d *.update | sed 's@.update$@@') |
for pkg in $(ls -d *.update | sed 's@.update$@@') |
196 |
do |
do |
|
orig=/etc/pootle/cvs/sme*/*/*7/$pkg/root/etc/e-smith/locale |
|
197 |
rm -f /var/www/html/patches/$(echo $pkg | sed 's/-[^-]\+$//')-*-locale-*.patch |
rm -f /var/www/html/patches/$(echo $pkg | sed 's/-[^-]\+$//')-*-locale-*.patch |
198 |
|
[ -d $pkg.update/root/etc/e-smith/locale ] || continue |
199 |
|
orig=/etc/pootle/cvs/sme*/*/*7/$pkg/root/etc/e-smith/locale |
200 |
diff -ruN $orig $pkg.update/root/etc/e-smith/locale \ |
diff -ruN $orig $pkg.update/root/etc/e-smith/locale \ |
201 |
| sed 's@^\(---\|+++\) [^ ]\+/\([^/]\+/root/.*\)@\1 \2@;/^diff -ruN/d' \ |
| sed 's@^\(---\|+++\) [^ ]\+/\([^/]\+/root/.*\)@\1 \2@;/^diff -ruN/d' \ |
202 |
> /var/www/html/patches/$pkg-locale-$(date +%F).patch |
> /var/www/html/patches/$pkg-locale-$(date +%F).patch |