Google Contacts Events Notifier can easily be configured so as to use another
language instead of English (which is the default) for the email
notifications.
This guide presents the main points of the translation process.
If you want to add a new translation of the notifications, open your script,
find the line reading var i18n
and have a look at the structure of the
translation object and at the instructions at the end.
The main idea is to build a little “dictionary” for each language to match the
English string with its translation in the given language.
To add a new language (e.g. Spanish - language code ‘es’):
Find the block of code which represents one existing translation and copy it, for example:
'it': {
'Age': 'Età',
...
'You can find the latest one here': 'Puoi trovare l\'ultima qui',
},
Paste it inside the list of translations respecting the alphabetical order for the language codes (in this case the new language code will be ‘es’, so we will put the new translation between ‘de’ and ‘fr’):
'de': {
'Age': 'Alter',
...
'You can find the latest one here': 'Du findest die neuste Version hier',
},
'it': {
'Age': 'Età',
...
'You can find the latest one here': 'Puoi trovare l\'ultima qui',
},
'fr': {
'Age': 'Age',
...
'You can find the latest one here': 'Vous pouvez trouver la dernière version ici',
},
Change the language code and remove all the copied translations on the right hand side:
'de': {
'Age': 'Alter',
...
'You can find the latest one here': 'Du findest die neuste Version hier',
},
'es': {
'Age': '',
...
'You can find the latest one here': '',
},
'fr': {
'Age': 'Age',
...
'You can find the latest one here': 'Vous pouvez trouver la dernière version ici',
},
Proceed to translate every item in the list, leaving the string on the left of
the :
unchanged and translating the one on the right, like this:
'de': {
'Age': 'Alter',
...
'You can find the latest one here': 'Du findest die neuste Version hier',
},
'es': {
'Age': 'Edad',
...
'You can find the latest one here': 'Puedes encontrar la última aquí',
},
'fr': {
'Age': 'Age',
...
'You can find the latest one here': 'Vous pouvez trouver la dernière version ici',
},
These are some things you have to keep in mind to do this correctly:
'
).\
) before it.Puoi trovare l'ultima qui
must
become 'Puoi trovare l\'ultima qui'
when enclosing it between the two
single quotes.'dd-MM-yyyy'
must not be translated or changed into other
alphabets: instead they can be used to change date formats in the language
you are translating into (e.g. a ‘en-US’ translation would use
'MM-dd-yyyy'
to display the date as month-day-year).Google Contacts Events Notifier is used by various users from around the world; if you want you can make your translation available to everyone by sharing it with us: we will be extremely happy to include it in the script in the next release.
Do you know your way around git and GitHub very well?
Then go to “Translation via git”.
You don’t know what we are talking about?
Not a problem: you can follow the “Translation via web”
guide.
You really cannot make your way around this whole “edit, comment and submit”
thing, but still would like to contribute in one way or another?
We have the right solution for you: the “Translation via issue”.
If you don’t know what git and GitHub are, but want to learn more about it you can read this guide written by a collaborator of this project.
Follow this guide only if you are quite familiar with how git and GitHub work.
master
branch, but against
development
(or another feature branch if appropriate).You might want to read the complete guide to contributing: most of it is not needed if you just want to contribute with a translation, but you still might find some of the info quite useful for contributing further.
Follow this guide if you are able to edit text files on the fly on the web.
First of all you will need to create a fork of this repository. A fork is a copy of the project that you can work on (editing, adding and deleting files for example). Once you are done working on the fork you will send those edits to us and we will analyze and merge them into the actual code of the script.
https://github.com/YOURUSERNAME/GoogleContactsEventsNotifier
.development
(unless it’s clearly stated
otherwise somewhere).Use this method only if you have tried the previous one and you are completely lost somewhere in the GitHub labyrinth.