-
Notifications
You must be signed in to change notification settings - Fork 19
/
TRANSLATE_README
65 lines (49 loc) · 2.64 KB
/
TRANSLATE_README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
# This README is dividied into two sections -
# first section is for the coverart-browser developers
# second section is for Translators
# Section 1: Developers Only
#+++++++++++++++++++++++++++
#for each ui file run the following to create translation .h files
intltool-extract --local --type=gettext/glade ui/coverart_artistview.ui
intltool-extract --local --type=gettext/glade ui/coverart_artist_pop_rb3.ui
intltool-extract --local --type=gettext/glade ui/coverart_browser_pop_rb3.ui
intltool-extract --local --type=gettext/glade ui/coverart_browser_prefs.ui
intltool-extract --local --type=gettext/glade ui/coverart_browser.ui
intltool-extract --local --type=gettext/glade ui/coverart_entryview_compact_pop_rb3.ui
intltool-extract --local --type=gettext/glade ui/coverart_entryview_full_pop_rb3.ui
intltool-extract --local --type=gettext/glade ui/coverart_exportembed.ui
intltool-extract --local --type=gettext/glade ui/coverart_leftsidebar.ui
intltool-extract --local --type=gettext/glade ui/coverart_listwindow.ui
intltool-extract --local --type=gettext/glade ui/coverart_play_pop_rb3.ui
intltool-extract --local --type=gettext/glade ui/coverart_rightsidebar.ui
intltool-extract --local --type=gettext/glade ui/coverart_topbar.ui
intltool-extract --local --type=gettext/xml img/popups.xml.in
#create a new template file called po/package.pot by running below
#create a template file for the mako templates
pybabel extract -F babel.cfg -o po/coverartbrowser.pot -c "TRANSLATORS:" .
# po/files_to_be_translated are all the .h files generated by intltool
xgettext -c -a -j -f po/files_to_be_translated -o po/coverartbrowser.pot
# po/py_files_to_be_translated are all the python files to be translated
xgettext -c -j -f po/py_files_to_be_translated -o po/coverartbrowser.pot
#now update existing po's with changes in the template file package.pot
cd po
./update_all_po.sh
#cleanup
cd ..
rm -rf tmp
# Section 2: Translators
#+++++++++++++++++++++++
The best way to create translations is to visit our Launchpad site
- https://translations.launchpad.net/coverartbrowser
Set your preferred language and then just begin translating
If you dont want to use Launchpad, use the following instructions
# Carry out the following - one or the other (or both!)
#create a new locale file from this template:
cd po; msginit --no-translator
#create a new specific (e.g. spanish) locale file from this template:
cd po; msginit --no-translator -l es
#Take special care with "Fuzzy" translations. "Fuzzy" lines should be
#removed - the string should be carefully examined since these are often
#automated translations.
#run lang.sh to compile and install the po files
sudo ./lang.sh /usr/share/locale/