Closed parkmino closed 5 years ago
This feature is on the roadmap.
It would be good to have the option to choose a language.
I would like to do the french translation
I am working in the locale branch on this feature. The general i18n functions are working and the frontend is translated to german. Now I am working on the backend to emit translatable messages to the frontend.
For each language there are now separate text files with a simple syntax in the directory src/i18n/. A perl script creates a javascipt / json file from this files (called by mkdebug.sh and mkrelease.sh).
The syntax of this translation files is described in the wiki: https://github.com/jcorporation/myMPD/wiki/Translating
Thanks a lot for your effort! ;-)
Yeah, I have been checking the locale branch from time to time. Please let me know when it is ready to add Korean translation. A couple of days would be enough for me to translate and I am considering to open another issue to attach ko-KR.txt file. PR seems too much for me only to upload the translated file.
My german translation is now finished. You can use the de-DE.txt file to translate myMPD in your language. Attaching a ko-KR.txt file is good enough, I can add it to the repository.
OK and I will statrt the translation.
Hmm... I translated the Korean and tried to test, however the following error message shows up in master build.
[ 20%] Building C object CMakeFiles/mympd.dir/src/mpd_client.c.o
/home/parkmino/Downloads/mpd/mympd/myMPD-master/src/mpd_client.c: In function ‘mpd_client_search_adv’:
/home/parkmino/Downloads/mpd/mympd/myMPD-master/src/mpd_client.c:3141:12: error: invalid type argument of unary ‘*’ (have ‘int’)
(void) *sortdesc;
^~~~~~~~~
/home/parkmino/Downloads/mpd/mympd/myMPD-master/src/mpd_client.c:3144:12: error: invalid type argument of unary ‘*’ (have ‘unsigned int’)
(void) *offset;
^~~~~~~
CMakeFiles/mympd.dir/build.make:110: recipe for target 'CMakeFiles/mympd.dir/src/mpd_client.c.o' failed
make[2]: *** [CMakeFiles/mympd.dir/src/mpd_client.c.o] Error 1
CMakeFiles/Makefile2:104: recipe for target 'CMakeFiles/mympd.dir/all' failed
make[1]: *** [CMakeFiles/mympd.dir/all] Error 2
Makefile:129: recipe for target 'all' failed
make: *** [all] Error 2
This error should now be fixed.
I put the translated ko-KR.txt file into i18n folder, however it is not listed in locale. Is there anything to check on my side?
The translation files must be added manually to the select in index.html. Automatic inclusion of translation files in the compile step comes in the next days.
Should now work, put your file in the i18n folder before calling ./mkrelease.sh. Please note that you must the write the friendly language name in the first line of the translation file.
I do not see Korean still. I separately run tojson.pl and put it in /usr/share/mympd/htdocs/js/i18n.min, then it woks.
mkrelease.sh now runs tojson.pl at build time.
Finally it works! Some translations seem missing as attached.
I added the missing hooks in source and the phrases to de-DE.txt. Commits: 76a2ab640317a21db35d83e2ce74488149186ba8, bd05722221e3bf284cbc24751a5264628f67c036
days/hours/minutes/seconds translation seems not to change properly according to the locale.
One more missing translation found.
days/hours/minutes/seconds translation seems not to change properly according to the locale.
I think that those should be appended to the relevant translation, not en-US.txt I added the days/hours/minutes/seconds translation to ko-KR.txt, and it shows fine.
Error on my side. Last commit added: Days, Hours, Minutes, Seconds and Background phrases to translation framework.
Thanks for your effort. Please find the attached file for the Korean translation.
I will close this issue at once, and open new one when any update is needed.
Your translation is now integrated in the repository. Thanks for your effort.
I would like to contribute Korean translation.