Important Dates

Latest Posts

Topic: Launchpad trap

Kristin

Topic Opener
Joined: 2009-04-05, 19:28
Posts: 81
Ranking
Likes to be here
Location: Germany
Posted at: 2010-02-14, 12:52

I just found a litte trap in the lauchpad translating tool: When you want to confirm a suggested translation or a current version, make sure to not only click on the suggestion (that makes it appear in the "new translation"window) but also click on the "new translation" window to activate it (=blue). If it isn't activated the new translation is not saved!


Top Quote
Marcelo_do_Pagode
Avatar
Joined: 2011-07-23, 18:59
Posts: 35
Ranking
Pry about Widelands
Location: Brazil
Posted at: 2011-08-01, 21:13

Another "problem" I have encountered is that when you download the tarball all the files inside are named with the structure <prefix>-<language>.po and you have to rename all files to strip its prefix in order to build the game correctly. For ex., in the maps directory all the translation files are named maps-<language>.po, while the compilation expects only <language>.po The same goes for all directories.

Cheers!

Edited: 2011-08-01, 21:14

Marcelo do Pagode
Ubuntu 11.04
Colorado com muito orgulho!

Top Quote
hjd

Joined: 2011-06-12, 20:24
Posts: 158
Ranking
At home in WL-forums
Location: bugs.launchpad.net/widelands
Posted at: 2011-08-01, 21:38

I think the main reason for providing tarballs is to allow translator to download all strings and translate them locally in whatever tool they prefer. However, I don't know for certain so someone else may have a better answer than me.

Though, if all you want to compile Widelands with the latest translations, you should take a look at https://answers.launchpad.net/widelands/+question/112229. Basically you need to merge the branch where the latest translations have been exported and recompile.

Edited: 2011-08-01, 21:40

Ships!

Top Quote
Marcelo_do_Pagode
Avatar
Joined: 2011-07-23, 18:59
Posts: 35
Ranking
Pry about Widelands
Location: Brazil
Posted at: 2011-08-01, 22:22

Thanks for the tip hjd! Thing is, I'm completely unfamiliar with bazaar :P I have build16 installed manualy in my system (ubuntu 11.04, source code downloaded from launchpad).

I have tried using simply $bzr merge lp:~sirver/widelands/translations

but I got: bzr: ERROR: Not a branch: "/home/marfcg/jogos/widelands-build16-src/".

I could use bazaar to fetch the branch, but that would mean downoading the whole source code again, which is huge... Is there a way to tell bazaar that I already have a version of widelands installed, give him the lp:widelands as the source and just merge with the latest version?

Edited: 2011-08-01, 22:23

Marcelo do Pagode
Ubuntu 11.04
Colorado com muito orgulho!

Top Quote
SirVer

Joined: 2009-02-19, 15:18
Posts: 1440
Ranking
One Elder of Players
Location: Germany - Munich
Posted at: 2011-08-02, 11:27

You could also to do some sed and awk magic:

prefix="maps-"; for i in *.po; do mv $i $(echo $i | sed "s/$prefix//"); done

Top Quote
Marcelo_do_Pagode
Avatar
Joined: 2011-07-23, 18:59
Posts: 35
Ranking
Pry about Widelands
Location: Brazil
Posted at: 2011-08-02, 22:36

SirVer: I have used the "rename" command with

rename 's/maps-//' *.po

which does all the work ;) You just have to be careful with the prefixes that have ".", which is a protected character, so you need something like

rename 's/scenario_atl01\.wmf-//' *.po

where the "\." tells the command to interpret the dot as part of the string and not a system symbol. But thanks for the suggestion nevertheless!

Edited: 2011-08-02, 22:37

Marcelo do Pagode
Ubuntu 11.04
Colorado com muito orgulho!

Top Quote