• Home
  • History
  • Annotate
Name Date Size #Lines LOC

..03-May-2022-

en/LC_MESSAGES/H25-May-2021-55,07843,267

es/LC_MESSAGES/H25-May-2021-60,94749,249

ja/LC_MESSAGES/H25-May-2021-1,5311,219

pot/H25-May-2021-49,99638,541

.gitignoreH A D25-May-202115 32

README.mdH A D25-May-20212.6 KiB154105

README.md

1
2
3# Locale
4
5Currently the setup is for  `es` `ru` `ja` `it` `de` `fr`
6
7## Building the LOCALE:
8
9Use this when the English documentation changed.
10
11```
12cd build
13#rm -rf *   #BE VERY CAREFULL
14cmake -D LOCALE=ON ..
15make locale
16cd ..
17sphinx-intl update -d locale
18```
19
20When there is a new resource
21```
22sphinx-intl update-txconfig-resources --locale-dir locale --pot-dir locale/pot --transifex-project-name pgrouting
23```
24
25
26review
27```
28for f in locale/pot/*; do echo $f; grep $f .tx/config; done
29for f in `grep '\.pot' .tx/config | sed 's/^.*pot\/\(.*\)$/\1/' | grep '\.pot'` ; do  echo $f; ls locale/pot/* | grep $f  ; done
30```
31
32commit changes and push
33
34## Cleanup unused messages
35
36Hint
37```
38for f in ${FILE}
39do
40    echo one ${f}
41    grep '#~' ${f}
42    msgattrib --output-file=${f} --no-obsolete ${f}
43    echo two
44    grep '#~' ${f}
45done
46```
47
48
49## MANAGERS: Interaction with transifex:
50
51### Push the resource to transifex
52
53Push a New or changed resource:
54
55* New resource
56
57Add the resource to the `.tx/config` located at the root of the repository
58(Use as example the other resources)
59
60```
61vim ../.tx/config
62```
63
64* Push the new resource
65```
66tx push --source -r pgrouting.pgr_createVerticesTable
67
68```
69Note: Do not put the file extension
70
71NOTE: INFORM: A documentation frezze to let translators translate
72
73### Pull the resources from transifex
74
75Be patient takes time (I like the `-d` flag just to know what is being downloaded)
76
77* this pulls all the translations
78```
79tx -d pull -f
80```
81
82* this pulls the Spanish translations
83```
84tx -d pull -f -l es
85```
86
87
88
89## TRANSLATORS
90
91For this example the translator is translating `pgr_createVerticesTable` to `Spanish`
92
93* Step 1: Build a local documentation
94
95```
96cd build
97rm -rf *
98cmake -D HTML=ON -D ES=ON ..
99make html-es
100```
101
102* Step 2: Navigate to the page you are translating:
103
104On the Browser go to:
105```
106file:///path/to/build/doc/_build/html/es/pgr_createVerticesTable.html
107```
108
109* Step 3: Pull the translation & build the documentation & refresh browser
110
111```
112tx pull -r pgrouting.pgr_createVerticesTable -l es
113make html-es
114```
115`Refresh browser`
116
117## Building the documentation:
118
119NOTE: in any case English is always build
120
121* Building all languages
122
123```
124cmake -D HTML=ON -D WITH_ALL_LANG=ON ..
125make doc
126```
127
128* Building a a particular language
129
130This example shows Spanish:
131
132```
133cmake -D HTML=ON -D ES=ON ..
134make html
135```
136
137* Building a particular language
138
139This example shows Spanish:
140
141```
142make -D HTML=ON -D SINGLEHTML=OM -D ES=ON ..
143make html
144make singlehtml
145# OR to build both:
146make doc
147```
148
149# References
150
151* https://pypi.python.org/pypi/sphinx-intl
152* https://docs.transifex.com/client/introduction
153* http://www.sphinx-doc.org/en/stable/intl.html
154