Created GeoNode Translation (markdown)

Luis Guzman 2020-04-23 01:51:29 -05:00
parent d9e852176b
commit 1cda1a221c
1 changed files with 52 additions and 0 deletions

52
GeoNode-Translation.md Normal file

@ -0,0 +1,52 @@
## Overall Translation
If you have a running GeoNode instance you might want to improve your language l10n.
Even when in the past GeoNode used a popular platform such as Transifex, that is no longer the case, meaning that you can improve your language l10n by making a PR with the latest translations to the main project in order to get them include on later releases, versions, commits.
## Maintaining Translations
In order to work on a translation that you might later submit as an PR, then first you want to fork the [the main project](https://github.com/GeoNode/geonode) and clone your fork locally.
```
git clone http://github.com/{{your_gh_user}}/geonode
```
Be aware of what branch you'll be working on, at the moment of writing the stable branch is:
* **2.10.x**
Once you have cloned your own copy with the latest commits, get into the git project directory and target to your desired branch to work on l10n. For practical use we'll target current (2.10.x) stable branch, creating a custom branch to work on your language.
```
git checkout -b l10n-work_{your_language} 2.10.x
```
Your are now set, please go to `~/geonode/geonode/locale/{lang}/LC_MESSAGES` and you would be able to edit *.po files.
We recommend to use a translation editor such as [Poedit](https://poedit.net/), since it is available on any GNU/Linux system.
Plus it will automatically apply updates to *.mo files.
Once you are satisfied with your changes you'll be able to make a PR to the main project in case you want to contribute back.
## Apply custom changes on Live Server
For this we'll assume you have a GeoNode install using the standard installer from source running with uwsgi.
You'll only need to copy your local repo updated *.po / *.mo files and copy them on the server locale directory
```
/opt/geonode/geonode/locale/{your_language}/LC_MESSAGES
```
Note: Make sure your copied files belong to the right user, most of the times it is *geonode*
```
chown -R geonode:geonode /opt/geonode/geonode/locale/
```
Once done, restart uwsgi service and you'll be able to see your changes applied.
```
service uwsgi restart
```