Re: schemas move



Am Fr, den 05.12.2003 schrieb Mark McLoughlin um 15:39:
> Hey guys,
> 	I've just moved desktop_gnome_url_handlers.schemas from libgnome to
> gnome-vfs.
> 
> 	I'd really like to have moved the translations for the schemas while I
> was at it, but I couldn't figure out a way to do it easily. If anyone
> could educate me ... I'd be happy to do it. It seems like a awful waste
> to make each translator do it individually ...
ok, the problem is that there might be different translations in
gnome-vfs for the same string that might be destroyed when doing a
simple msgmerge. Therefore you should do this (put up a shellscript
similar to this). You might want to check whether each po file exists in
both modules, but here is the basic pattern:
#!/bin/bash
mv POTFILES.in POTFILES.in.backup &&
echo "desktop_gnome_url_handlers.schemas" > POTFILES.in &&
intltool-update -p &&
mv gnome-vfs-2.0.pot gnome-vfs-2.0.pot.old &&
cat gnome-vfs-2.0.pot.old | sed 's/\(charset=\)CHARSET/\1UTF-8/' > \
gnome-vfs-2.0.pot;
rm gnome-vfs-2.0.pot.old

for i in $( ls *.po );
	do mv $i $i.old;
	msgmerge -o $i.new.schema.in ../libgnome/po/$i gnome-vfs-2.0.pot ;
	grep -v ^#~ $i.new.schema.in $i.new.schema;
#^^ don't include fuzzy lines. Those will overwrite old defs.
	msgmerge -o $i $i.new.schema $i.old;
	rm $.old $i.new.schema;
	done;

mv POTFILES.in.backup POTFILES.in;

that's it.

regs,
 Chris




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]