Forum: Rails I18n Complex folder estructure inside locale translated

Adce10d7f1dbabcdab8f525a59cec32f?d=identicon&s=25 Andrés Gutiérrez (andresgutgon)
on 2010-06-07 15:03
(Received via mailing list)
Hello I've been watching these two projects [1] and [2]. Both look good.
But
I see it is not possible to have a complex structure inside the locale
folder.

The two projects  caught the .yml and displayed in a web interface for
ease
translate each string.

But with a Base of folders a bit complex. Example:

locale
  |-es.yml
  |-models
      |-users
          |-es.yml
      |-articles
          |-es.yml
  |-views
      |-users
      |--articles
  formtastic
     |-es.yml

It is possible to translate this. Or should I put all the strings in a
single file?


[1] http://github.com/newsdesk/translate
[2] http://github.com/dhh/tolk
Adce10d7f1dbabcdab8f525a59cec32f?d=identicon&s=25 Andrés Gutiérrez (andresgutgon)
on 2010-06-08 12:46
(Received via mailing list)
On Jun 7, 3:02 pm, Andrés gutiérrez <andresgut...@gmail.com> wrote:
>   |-es.yml
>
> It is possible to translate this. Or should I put all the strings in a
> single file?
>
> [1]http://github.com/newsdesk/translate
> [2]http://github.com/dhh/tolk

Please, Does anyone else separated into folders or am I the only one?
42ec9fd08c179b547dcb60d977e29941?d=identicon&s=25 Iain Hecker (Guest)
on 2010-06-08 13:13
(Received via mailing list)
Hi,

I don't really know what to do. Both using many files and one single
file have their advantages and disadvantages. One file can get a big
mess, but many files are hard to find stuff.

Sometimes I wish the scopes were all backwards: Then you would be able
to group translations together based upon their functionality instead
of their usage.

I don't use any of these projects yet, but I am going to use tolk in
the near future, so I can't say anything about that yet.

- iain
Adce10d7f1dbabcdab8f525a59cec32f?d=identicon&s=25 Andrés Gutiérrez (andresgutgon)
on 2010-06-08 13:27
(Received via mailing list)
2010/6/8 Iain Hecker <iain@iain.nl>

> I don't use any of these projects yet, but I am going to use tolk in
> the near future, so I can't say anything about that yet.
>

Thanks Ian for the reply. I see it is a question that not only do I have
right?
Adce10d7f1dbabcdab8f525a59cec32f?d=identicon&s=25 Andrés Gutiérrez (andresgutgon)
on 2010-06-08 13:27
(Received via mailing list)
El 8 de junio de 2010 13:25, Andrés gutiérrez
<andresgutgon@gmail.com>escribió:

>> Sometimes I wish the scopes were all backwards: Then you would be able
>> to group translations together based upon their functionality instead
>> of their usage.
>>
>> I don't use any of these projects yet, but I am going to use tolk in
>> the near future, so I can't say anything about that yet.
>>
>
> Thanks Ian for the reply. I see it is a question that not only do I have
> right?
>
Sorry Iain no Ian
42ec9fd08c179b547dcb60d977e29941?d=identicon&s=25 Iain Hecker (Guest)
on 2010-06-08 14:53
(Received via mailing list)
We had this discussion at my company. Nobody really knew what to do.
Does anybody else have the problem?

-iain

2010/6/8 Andrés gutiérrez <andresgutgon@gmail.com>:
Bad9247edfb251a4165fc45ca88655b7?d=identicon&s=25 Edouard (Guest)
on 2010-06-08 15:50
(Received via mailing list)
Hi,

At my company we made a web application that does just that.

http://webtranslateit.com

It’s a commercial software. We are working with companies having
projects with several hundreds of deeply nested language files, so
this kind of scenario was a requirement.
You can read in the documentation how it handles complex file
structures.

http://docs.webtranslateit.com/file_manager/#file_structure

Regards,
Édouard
Adce10d7f1dbabcdab8f525a59cec32f?d=identicon&s=25 Andrés Gutiérrez (andresgutgon)
on 2010-06-08 16:07
(Received via mailing list)
2010/6/8 Edouard <edouard.briere@gmail.com>

> structures.
>
> http://docs.webtranslateit.com/file_manager/#file_structure
>
> Regards,
> Édouard
>

Thanks  Édouard, looks great, but mine is a personal and no comercial
project. And i would like to manage this problem localy...in this moment
Adce10d7f1dbabcdab8f525a59cec32f?d=identicon&s=25 Andrés Gutiérrez (andresgutgon)
on 2010-06-08 16:19
(Received via mailing list)
El 8 de junio de 2010 16:06, Andrés gutiérrez
<andresgutgon@gmail.com>escribió:

>> It’s a commercial software. We are working with companies having
>
> Thanks  Édouard, looks great, but mine is a personal and no comercial
> project. And i would like to manage this problem localy...in this moment
>
>>
>> Sorry i'm reading more. And wti is more powerful :O  [1]

Thanks

[1] http://docs.webtranslateit.com/ruby_on_rails/
5593e947464934af2ed2294f696960f0?d=identicon&s=25 Tokumine (Guest)
on 2010-07-17 14:33
(Received via mailing list)
Hey there - I manage my base local in nested directories, and then
aggregate into a top level en.yml that I send off to tolk for
translation. Keeping my base locale in nested directories and my
translations at the top level is working well.

Here's a write up with a rake task to aggregate your base locales:
http://www.tokumine.com/2010/07/16/using-split-loc...

Si
7e565a1681dc0137f43826aa840686af?d=identicon&s=25 Andrés Mejía (Guest)
on 2010-07-17 17:19
(Received via mailing list)
I also keep my English locale in several files, but I don't really need
to
aggregate them to import it to Tolk. When I run tolk:sync it seems to
read
all my .yml files inside config/locales.
Adce10d7f1dbabcdab8f525a59cec32f?d=identicon&s=25 Andrés Gutiérrez (andresgutgon)
on 2010-07-18 22:46
(Received via mailing list)
El 17 de julio de 2010 17:18, Andrés Mejía <andmej@gmail.com> escribió:

> I also keep my English locale in several files, but I don't really need to
> aggregate them to import it to Tolk. When I run tolk:sync it seems to read
> all my .yml files inside config/locales.
>
> Thanks guys! this a recurrent problem for me. I'll try your suggestions.
Adce10d7f1dbabcdab8f525a59cec32f?d=identicon&s=25 Andrés Gutiérrez (andresgutgon)
on 2010-08-14 21:50
(Received via mailing list)
2010/7/17 Tokumine <si.tokumine@gmail.com>

> Hey there - I manage my base local in nested directories, and then
> aggregate into a top level en.yml that I send off to tolk for
> translation. Keeping my base locale in nested directories and my
> translations at the top level is working well.
>
> Here's a write up with a rake task to aggregate your base locales:
> http://www.tokumine.com/2010/07/16/using-split-loc...
>

I'm trying this, this is my rake task [1] but dosn't work
What i'm doing bad?

[1] http://www.pastie.org/1092435
7e565a1681dc0137f43826aa840686af?d=identicon&s=25 Andrés Mejía (Guest)
on 2010-08-14 23:18
(Received via mailing list)
I don't really think you need that rake task. I split my English locale
into
several files, like this:

[image: 20100814-899ktjfem9fqe2ia8dgjxq8hrb.png]

When I run rake tolk:sync or rake tolk:import it automatically picks all
my
English files without doing anything else. The fr.yml locale you see in
the
screenshot was generated using rake tolk:dump_all.

2010/8/14 Andrés gutiérrez <andresgutgon@gmail.com>
Adce10d7f1dbabcdab8f525a59cec32f?d=identicon&s=25 Andrés Gutiérrez (andresgutgon)
on 2010-08-15 11:28
(Received via mailing list)
El 14 de agosto de 2010 23:16, Andrés Mejía <andmej@gmail.com> escribió:

> I don't really think you need that rake task. I split my English locale
> into several files, like this:
>
> [image: 20100814-899ktjfem9fqe2ia8dgjxq8hrb.png]
>
> When I run rake tolk:sync or rake tolk:import it automatically picks all
> my English files without doing anything else. The fr.yml locale you see in
> the screenshot was generated using rake tolk:dump_all.
>

That is correct. I  have a similar estructure, but my problem is with
default rails locale files [1]

I downloaded ca.yml and en.yml and bouth are in /locale/defaults
When i run rake tolk:import This  task don't find this files. So i need
to
merge this files with the root files (ca.yml and en.yml) generated by
Tolk

[1] http://github.com/svenfuchs/rails-i18n
This topic is locked and can not be replied to.