2011-06-29 19:17:50 +02:00
|
|
|
.. highlight:: bash
|
|
|
|
|
|
|
|
.. _contribute-translate:
|
|
|
|
|
|
|
|
********************
|
|
|
|
Translating Limnoria
|
|
|
|
********************
|
|
|
|
|
2014-06-07 20:28:08 +02:00
|
|
|
I already wrote a `guide on how to translate`_ plugins.
|
2011-06-29 19:17:50 +02:00
|
|
|
So, this page will only explain how to translate the core and push your
|
|
|
|
translations to Limnoria.
|
|
|
|
|
|
|
|
.. _guide on how to translate: https://github.com/ProgVal/Supybot-docs/blob/master/i18n/Limnoria_i18n.pdf?raw=true
|
|
|
|
|
|
|
|
The best way: using Git yourself
|
|
|
|
================================
|
|
|
|
|
|
|
|
As I said in the :ref:`policy about developer's contributions
|
|
|
|
<contribute-develop-policy>`, I don't give write access to my repo for the
|
|
|
|
moment, but I accept pull requests.
|
|
|
|
|
|
|
|
As you are a translator, you don't need to know all the technical details
|
|
|
|
about development, so I write a simplified doc here.
|
|
|
|
|
|
|
|
Cloning the repository
|
|
|
|
----------------------
|
|
|
|
|
|
|
|
You first need an account on `GitHub`_; I think you don't need explaination
|
|
|
|
for that.
|
|
|
|
|
|
|
|
Then, go on `Limnoria repository`_ and click the *Fork* button. This will
|
|
|
|
create you a copy of my repository where you will have write access (and
|
|
|
|
I won't have this write access).
|
|
|
|
|
|
|
|
Then, open a console, and write (replace *YourName* by the name of your
|
|
|
|
GitHub account)::
|
|
|
|
|
2014-06-07 20:28:08 +02:00
|
|
|
git clone git@github.com:YourName/Limnoria.git --branch=testing
|
2011-06-29 19:17:50 +02:00
|
|
|
|
|
|
|
This will create a new directory, called *Limnoria*, where all the code and
|
|
|
|
project history are copied. Now, cd to the directory::
|
|
|
|
|
|
|
|
cd Limnoria/
|
|
|
|
|
2014-06-07 20:28:08 +02:00
|
|
|
The things below affect to you only if you didn't specify the branch in
|
|
|
|
the git clone command.
|
|
|
|
|
2011-06-29 19:17:50 +02:00
|
|
|
Then, you need to checkout the *testing* branch. What does that mean? It means
|
|
|
|
that there is differents stages in Limnoria: all changes are made in testing,
|
|
|
|
and when I think *testing* is stable, I merge it into *master*.
|
|
|
|
So, checking out *testing* means Git will use the code in *testing*, you
|
|
|
|
will translate strings that are in *testing*, and changes you make will be
|
|
|
|
in *testing*. Now, do it::
|
|
|
|
|
2014-06-07 20:28:08 +02:00
|
|
|
git checkout testing
|
2011-06-29 19:17:50 +02:00
|
|
|
|
|
|
|
Git will reply you that it understood what you mean by *testing*.
|
|
|
|
|
|
|
|
Ok, now, you can translate.
|
|
|
|
|
|
|
|
Pushing translations
|
|
|
|
--------------------
|
|
|
|
|
|
|
|
Once you have done some translations (let's say you translated Alias), you
|
|
|
|
have to commit your changes. That mean you tell Git "Ok, I've made some
|
|
|
|
changes, and I want to take a snapshot (either to be able to roll back
|
|
|
|
or to publish your changes).
|
|
|
|
|
|
|
|
First, you need to tell Git what files you want to be committed (let's say
|
|
|
|
you are the Finnish translator, so you updated Alias's fi.po)::
|
|
|
|
|
2013-05-24 20:11:51 +02:00
|
|
|
git add plugins/Alias/locales/fi.po
|
2011-06-29 19:17:50 +02:00
|
|
|
|
|
|
|
Then, you can commit your files. Depending on what you made, you can use
|
|
|
|
one of this commands (not all of them!)::
|
|
|
|
|
|
|
|
git commit -m "Alias: Add l10n-fi."
|
|
|
|
git commit -m "Alias: Update l10n-fi."
|
|
|
|
git commit -m "Alias: Fix l10n-fi."
|
|
|
|
|
|
|
|
By the way, the text that follow -m is a message that will be readed by
|
|
|
|
**humans**, so you can write anything you want, but I think it's better that
|
|
|
|
everybody use the same kind of messages.
|
|
|
|
|
|
|
|
Ok, then, Git knows you have done something. But you didn't send your work on
|
|
|
|
Internet yet. To send it, run::
|
|
|
|
|
|
|
|
git push
|
|
|
|
|
2014-06-07 20:28:08 +02:00
|
|
|
Simple, isn't it?
|
2011-06-29 19:17:50 +02:00
|
|
|
|
2014-06-07 20:28:08 +02:00
|
|
|
Now, go back to GitHub and your forked repository, and click the *Pull request*
|
2011-06-29 19:17:50 +02:00
|
|
|
button. Then, set *testing* on the both side, and run *Update Commit Range*.
|
|
|
|
I will by mailed that you asked me to merge your changes, and I will do it
|
|
|
|
soon.
|
|
|
|
|
|
|
|
Getting updates
|
|
|
|
---------------
|
|
|
|
|
|
|
|
As you may know, I do some updates in Limnoria repository. ;)
|
|
|
|
|
|
|
|
You need to have the latest version of the *messages.pot* files. So, you
|
|
|
|
need to teach Git how to get this updates::
|
|
|
|
|
2014-06-07 20:28:08 +02:00
|
|
|
git remote add upstream git://github.com/ProgVal/Limnoria.git
|
2011-06-29 19:17:50 +02:00
|
|
|
|
|
|
|
Now, every time you want to download updates, run::
|
|
|
|
|
2014-06-07 20:28:08 +02:00
|
|
|
git fetch upstream
|
|
|
|
git merge upstream/testing
|
2011-06-29 19:17:50 +02:00
|
|
|
|
|
|
|
Another way: mailing me your translations
|
|
|
|
=========================================
|
|
|
|
|
|
|
|
I think this is the simplest way for you. You only have to follow the
|
|
|
|
translation guide and send me your .po files by mail.
|
|
|
|
|
|
|
|
You can choose either one of this way to do it.
|
|
|
|
|
2014-06-07 20:28:08 +02:00
|
|
|
Mikaela's way
|
2014-06-30 21:46:06 +02:00
|
|
|
-------------
|
2011-06-29 19:17:50 +02:00
|
|
|
|
2014-06-07 20:28:08 +02:00
|
|
|
Send the fi.po (or whatever the name is) files one by one as an attachment.
|
2011-06-29 19:17:50 +02:00
|
|
|
Don't forget to tell me what plugin it is.
|
|
|
|
|
2014-06-07 20:28:08 +02:00
|
|
|
I (Mikaela) have moved to git long time ago though.
|
|
|
|
|
2011-06-29 19:17:50 +02:00
|
|
|
skizzhg's way
|
|
|
|
-------------
|
|
|
|
|
|
|
|
Do many translations. Put them in a tarball/zipball/whatever (but not a RAR
|
2014-06-07 20:28:08 +02:00
|
|
|
archive, I can't read them because is a proprietary format).
|
2011-06-29 19:17:50 +02:00
|
|
|
|
|
|
|
I prefer that you choose this architecture:
|
|
|
|
|
2013-05-24 20:11:51 +02:00
|
|
|
* FirstPlugin/locales/it.po
|
|
|
|
* SecondPlugin/locales/it.po
|
|
|
|
* ThirdPlugin/locales/it.po
|
2011-06-29 19:17:50 +02:00
|
|
|
|
|
|
|
Because I can extract everything with one click.
|
|
|
|
|
|
|
|
.. _GitHub: https://github.com/
|
|
|
|
.. _Limnoria repository: https://github.com/ProgVal/Limnoria
|