Ejemplos en Español

classic Classic list List threaded Threaded
31 messages Options
12
Reply | Threaded
Open this post in threaded view
|

Ejemplos en Español

David Blevins-2
I was talking with Hillmer on twitter about potentially translating examples into Spanish.

The idea is that we could potentially do examples and documentation in Spanish.  Perhaps:

 - http://tomee.apache.org/tomee-8.0/es/docs/
 - http://tomee.apache.org/tomee-8.0/es/ejemplos/

First note is that how we organize the files in the git repo and how we organize them on the website can be completely different.  We use the following code to collect all the examples together and do various things to them:

 - https://github.com/apache/tomee-site-generator/blob/master/src/main/java/org/apache/tomee/website/Examples.java#L42

Right now it will do a copy and rename, for example:

 - https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README.md
 - http://tomee.apache.org/tomee-8.0/examples/cdi-request-scope.html

We could theoretically do something as simple as this:

 - https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README_es.md
 - http://tomee.apache.org/tomee-8.0/es/ejemplos/cdi-request-scope.html

I.e. make a new file next to the original, then update our copying logic to put the prefix in the path.


Thoughts?


--
David Blevins
http://twitter.com/dblevins
http://www.tomitribe.com

Reply | Threaded
Open this post in threaded view
|

Re: Ejemplos en Español

Mohammed Aboullaite
I think its a brilliant idea. it'll open the door for not only Spanish, but
other languages as well (I'm thinking of French as well).



On Mon, Dec 24, 2018, 11:35 PM David Blevins <[hidden email] wrote:

> I was talking with Hillmer on twitter about potentially translating
> examples into Spanish.
>
> The idea is that we could potentially do examples and documentation in
> Spanish.  Perhaps:
>
>  - http://tomee.apache.org/tomee-8.0/es/docs/
>  - http://tomee.apache.org/tomee-8.0/es/ejemplos/
>
> First note is that how we organize the files in the git repo and how we
> organize them on the website can be completely different.  We use the
> following code to collect all the examples together and do various things
> to them:
>
>  -
> https://github.com/apache/tomee-site-generator/blob/master/src/main/java/org/apache/tomee/website/Examples.java#L42
>
> Right now it will do a copy and rename, for example:
>
>  -
> https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README.md
>  - http://tomee.apache.org/tomee-8.0/examples/cdi-request-scope.html
>
> We could theoretically do something as simple as this:
>
>  -
> https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README_es.md
>  - http://tomee.apache.org/tomee-8.0/es/ejemplos/cdi-request-scope.html
>
> I.e. make a new file next to the original, then update our copying logic
> to put the prefix in the path.
>
>
> Thoughts?
>
>
> --
> David Blevins
> http://twitter.com/dblevins
> http://www.tomitribe.com
>
>
Reply | Threaded
Open this post in threaded view
|

Re: Ejemplos en Español

David Blevins-2
I say “game on” to any languages people want to contribute :)

In fact, let the PRs fly. I’ll write the site logic this week.

-David

On Mon, Dec 24, 2018 at 2:45 PM Mohammed Aboullaite <
[hidden email]> wrote:

> I think its a brilliant idea. it'll open the door for not only Spanish, but
> other languages as well (I'm thinking of French as well).
>
>
>
> On Mon, Dec 24, 2018, 11:35 PM David Blevins <[hidden email]
> wrote:
>
> > I was talking with Hillmer on twitter about potentially translating
> > examples into Spanish.
> >
> > The idea is that we could potentially do examples and documentation in
> > Spanish.  Perhaps:
> >
> >  - http://tomee.apache.org/tomee-8.0/es/docs/
> >  - http://tomee.apache.org/tomee-8.0/es/ejemplos/
> >
> > First note is that how we organize the files in the git repo and how we
> > organize them on the website can be completely different.  We use the
> > following code to collect all the examples together and do various things
> > to them:
> >
> >  -
> >
> https://github.com/apache/tomee-site-generator/blob/master/src/main/java/org/apache/tomee/website/Examples.java#L42
> >
> > Right now it will do a copy and rename, for example:
> >
> >  -
> >
> https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README.md
> >  - http://tomee.apache.org/tomee-8.0/examples/cdi-request-scope.html
> >
> > We could theoretically do something as simple as this:
> >
> >  -
> >
> https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README_es.md
> >  - http://tomee.apache.org/tomee-8.0/es/ejemplos/cdi-request-scope.html
> >
> > I.e. make a new file next to the original, then update our copying logic
> > to put the prefix in the path.
> >
> >
> > Thoughts?
> >
> >
> > --
> > David Blevins
> > http://twitter.com/dblevins
> > http://www.tomitribe.com
> >
> >
>
--
Sent from my iPhone
Reply | Threaded
Open this post in threaded view
|

Re: Ejemplos en Español

Daniel Dias Dos Santos
+1  :  )
--

*Daniel Dias dos Santos*
Java Developer
SouJava & JCP Member
GitHub: https://github.com/Daniel-Dos
Linkedin: www.linkedin.com/in/danieldiasjava
Twitter: http://twitter.com/danieldiasjava


Em seg, 24 de dez de 2018 às 21:28, David Blevins <[hidden email]>
escreveu:

> I say “game on” to any languages people want to contribute :)
>
> In fact, let the PRs fly. I’ll write the site logic this week.
>
> -David
>
> On Mon, Dec 24, 2018 at 2:45 PM Mohammed Aboullaite <
> [hidden email]> wrote:
>
> > I think its a brilliant idea. it'll open the door for not only Spanish,
> but
> > other languages as well (I'm thinking of French as well).
> >
> >
> >
> > On Mon, Dec 24, 2018, 11:35 PM David Blevins <[hidden email]
> > wrote:
> >
> > > I was talking with Hillmer on twitter about potentially translating
> > > examples into Spanish.
> > >
> > > The idea is that we could potentially do examples and documentation in
> > > Spanish.  Perhaps:
> > >
> > >  - http://tomee.apache.org/tomee-8.0/es/docs/
> > >  - http://tomee.apache.org/tomee-8.0/es/ejemplos/
> > >
> > > First note is that how we organize the files in the git repo and how we
> > > organize them on the website can be completely different.  We use the
> > > following code to collect all the examples together and do various
> things
> > > to them:
> > >
> > >  -
> > >
> >
> https://github.com/apache/tomee-site-generator/blob/master/src/main/java/org/apache/tomee/website/Examples.java#L42
> > >
> > > Right now it will do a copy and rename, for example:
> > >
> > >  -
> > >
> >
> https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README.md
> > >  - http://tomee.apache.org/tomee-8.0/examples/cdi-request-scope.html
> > >
> > > We could theoretically do something as simple as this:
> > >
> > >  -
> > >
> >
> https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README_es.md
> > >  -
> http://tomee.apache.org/tomee-8.0/es/ejemplos/cdi-request-scope.html
> > >
> > > I.e. make a new file next to the original, then update our copying
> logic
> > > to put the prefix in the path.
> > >
> > >
> > > Thoughts?
> > >
> > >
> > > --
> > > David Blevins
> > > http://twitter.com/dblevins
> > > http://www.tomitribe.com
> > >
> > >
> >
> --
> Sent from my iPhone
>
Reply | Threaded
Open this post in threaded view
|

Re: Ejemplos en Español

brunobat
In reply to this post by David Blevins-2
+1

Bruno Baptista
https://twitter.com/brunobat_


On 24/12/18 22:35, David Blevins wrote:

> I was talking with Hillmer on twitter about potentially translating examples into Spanish.
>
> The idea is that we could potentially do examples and documentation in Spanish.  Perhaps:
>
>   - http://tomee.apache.org/tomee-8.0/es/docs/
>   - http://tomee.apache.org/tomee-8.0/es/ejemplos/
>
> First note is that how we organize the files in the git repo and how we organize them on the website can be completely different.  We use the following code to collect all the examples together and do various things to them:
>
>   - https://github.com/apache/tomee-site-generator/blob/master/src/main/java/org/apache/tomee/website/Examples.java#L42
>
> Right now it will do a copy and rename, for example:
>
>   - https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README.md
>   - http://tomee.apache.org/tomee-8.0/examples/cdi-request-scope.html
>
> We could theoretically do something as simple as this:
>
>   - https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README_es.md
>   - http://tomee.apache.org/tomee-8.0/es/ejemplos/cdi-request-scope.html
>
> I.e. make a new file next to the original, then update our copying logic to put the prefix in the path.
>
>
> Thoughts?
>
>
Reply | Threaded
Open this post in threaded view
|

Re: Ejemplos en Español

Daniel Cunha
+1

Em qua, 26 de dez de 2018 7:34 AM, Bruno Baptista <[hidden email]
escreveu:

> +1
>
> Bruno Baptista
> https://twitter.com/brunobat_
>
>
> On 24/12/18 22:35, David Blevins wrote:
> > I was talking with Hillmer on twitter about potentially translating
> examples into Spanish.
> >
> > The idea is that we could potentially do examples and documentation in
> Spanish.  Perhaps:
> >
> >   - http://tomee.apache.org/tomee-8.0/es/docs/
> >   - http://tomee.apache.org/tomee-8.0/es/ejemplos/
> >
> > First note is that how we organize the files in the git repo and how we
> organize them on the website can be completely different.  We use the
> following code to collect all the examples together and do various things
> to them:
> >
> >   -
> https://github.com/apache/tomee-site-generator/blob/master/src/main/java/org/apache/tomee/website/Examples.java#L42
> >
> > Right now it will do a copy and rename, for example:
> >
> >   -
> https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README.md
> >   - http://tomee.apache.org/tomee-8.0/examples/cdi-request-scope.html
> >
> > We could theoretically do something as simple as this:
> >
> >   -
> https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README_es.md
> >   - http://tomee.apache.org/tomee-8.0/es/ejemplos/cdi-request-scope.html
> >
> > I.e. make a new file next to the original, then update our copying logic
> to put the prefix in the path.
> >
> >
> > Thoughts?
> >
> >
>
Reply | Threaded
Open this post in threaded view
|

Re: Ejemplos en Español

Otávio Gonçalves de Santana
+1

On Wed, Dec 26, 2018 at 9:11 AM Daniel Cunha <[hidden email]> wrote:

> +1
>
> Em qua, 26 de dez de 2018 7:34 AM, Bruno Baptista <[hidden email]
> escreveu:
>
> > +1
> >
> > Bruno Baptista
> > https://twitter.com/brunobat_
> >
> >
> > On 24/12/18 22:35, David Blevins wrote:
> > > I was talking with Hillmer on twitter about potentially translating
> > examples into Spanish.
> > >
> > > The idea is that we could potentially do examples and documentation in
> > Spanish.  Perhaps:
> > >
> > >   - http://tomee.apache.org/tomee-8.0/es/docs/
> > >   - http://tomee.apache.org/tomee-8.0/es/ejemplos/
> > >
> > > First note is that how we organize the files in the git repo and how we
> > organize them on the website can be completely different.  We use the
> > following code to collect all the examples together and do various things
> > to them:
> > >
> > >   -
> >
> https://github.com/apache/tomee-site-generator/blob/master/src/main/java/org/apache/tomee/website/Examples.java#L42
> > >
> > > Right now it will do a copy and rename, for example:
> > >
> > >   -
> >
> https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README.md
> > >   - http://tomee.apache.org/tomee-8.0/examples/cdi-request-scope.html
> > >
> > > We could theoretically do something as simple as this:
> > >
> > >   -
> >
> https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README_es.md
> > >   -
> http://tomee.apache.org/tomee-8.0/es/ejemplos/cdi-request-scope.html
> > >
> > > I.e. make a new file next to the original, then update our copying
> logic
> > to put the prefix in the path.
> > >
> > >
> > > Thoughts?
> > >
> > >
> >
>
Reply | Threaded
Open this post in threaded view
|

Re: Ejemplos en Español

César Hernández Mendoza
+1
I can definitely help on this one and amplify the initiative to the Latin
America community on the translation epic :)!

I created the main Task for this initiative:
https://issues.apache.org/jira/browse/TOMEE-2442

@David, do you have already a PR that can be associated with this Task?


El vie., 28 dic. 2018 a las 8:13, Otávio Gonçalves de Santana (<
[hidden email]>) escribió:

> +1
>
> On Wed, Dec 26, 2018 at 9:11 AM Daniel Cunha <[hidden email]> wrote:
>
> > +1
> >
> > Em qua, 26 de dez de 2018 7:34 AM, Bruno Baptista <[hidden email]
> > escreveu:
> >
> > > +1
> > >
> > > Bruno Baptista
> > > https://twitter.com/brunobat_
> > >
> > >
> > > On 24/12/18 22:35, David Blevins wrote:
> > > > I was talking with Hillmer on twitter about potentially translating
> > > examples into Spanish.
> > > >
> > > > The idea is that we could potentially do examples and documentation
> in
> > > Spanish.  Perhaps:
> > > >
> > > >   - http://tomee.apache.org/tomee-8.0/es/docs/
> > > >   - http://tomee.apache.org/tomee-8.0/es/ejemplos/
> > > >
> > > > First note is that how we organize the files in the git repo and how
> we
> > > organize them on the website can be completely different.  We use the
> > > following code to collect all the examples together and do various
> things
> > > to them:
> > > >
> > > >   -
> > >
> >
> https://github.com/apache/tomee-site-generator/blob/master/src/main/java/org/apache/tomee/website/Examples.java#L42
> > > >
> > > > Right now it will do a copy and rename, for example:
> > > >
> > > >   -
> > >
> >
> https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README.md
> > > >   -
> http://tomee.apache.org/tomee-8.0/examples/cdi-request-scope.html
> > > >
> > > > We could theoretically do something as simple as this:
> > > >
> > > >   -
> > >
> >
> https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README_es.md
> > > >   -
> > http://tomee.apache.org/tomee-8.0/es/ejemplos/cdi-request-scope.html
> > > >
> > > > I.e. make a new file next to the original, then update our copying
> > logic
> > > to put the prefix in the path.
> > > >
> > > >
> > > > Thoughts?
> > > >
> > > >
> > >
> >
>


--
Atentamente:
César Hernández Mendoza.
Reply | Threaded
Open this post in threaded view
|

Re: Ejemplos en Español

Rodrigo Graciano
I can help with Portuguese

On Wed, Jan 2, 2019 at 7:10 PM César Hernández Mendoza <[hidden email]>
wrote:

> +1
> I can definitely help on this one and amplify the initiative to the Latin
> America community on the translation epic :)!
>
> I created the main Task for this initiative:
> https://issues.apache.org/jira/browse/TOMEE-2442
>
> @David, do you have already a PR that can be associated with this Task?
>
>
> El vie., 28 dic. 2018 a las 8:13, Otávio Gonçalves de Santana (<
> [hidden email]>) escribió:
>
> > +1
> >
> > On Wed, Dec 26, 2018 at 9:11 AM Daniel Cunha <[hidden email]>
> wrote:
> >
> > > +1
> > >
> > > Em qua, 26 de dez de 2018 7:34 AM, Bruno Baptista <[hidden email]
> > > escreveu:
> > >
> > > > +1
> > > >
> > > > Bruno Baptista
> > > > https://twitter.com/brunobat_
> > > >
> > > >
> > > > On 24/12/18 22:35, David Blevins wrote:
> > > > > I was talking with Hillmer on twitter about potentially translating
> > > > examples into Spanish.
> > > > >
> > > > > The idea is that we could potentially do examples and documentation
> > in
> > > > Spanish.  Perhaps:
> > > > >
> > > > >   - http://tomee.apache.org/tomee-8.0/es/docs/
> > > > >   - http://tomee.apache.org/tomee-8.0/es/ejemplos/
> > > > >
> > > > > First note is that how we organize the files in the git repo and
> how
> > we
> > > > organize them on the website can be completely different.  We use the
> > > > following code to collect all the examples together and do various
> > things
> > > > to them:
> > > > >
> > > > >   -
> > > >
> > >
> >
> https://github.com/apache/tomee-site-generator/blob/master/src/main/java/org/apache/tomee/website/Examples.java#L42
> > > > >
> > > > > Right now it will do a copy and rename, for example:
> > > > >
> > > > >   -
> > > >
> > >
> >
> https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README.md
> > > > >   -
> > http://tomee.apache.org/tomee-8.0/examples/cdi-request-scope.html
> > > > >
> > > > > We could theoretically do something as simple as this:
> > > > >
> > > > >   -
> > > >
> > >
> >
> https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README_es.md
> > > > >   -
> > > http://tomee.apache.org/tomee-8.0/es/ejemplos/cdi-request-scope.html
> > > > >
> > > > > I.e. make a new file next to the original, then update our copying
> > > logic
> > > > to put the prefix in the path.
> > > > >
> > > > >
> > > > > Thoughts?
> > > > >
> > > > >
> > > >
> > >
> >
>
>
> --
> Atentamente:
> César Hernández Mendoza.
>
--

Rodrigo Graciano
[hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: Ejemplos en Español

cchacin
In reply to this post by Daniel Dias Dos Santos
+1 please let me know how I can help

On Mon, Dec 24, 2018, 8:24 PM Daniel Dias Dos Santos <
[hidden email] wrote:

> +1  :  )
> --
>
> *Daniel Dias dos Santos*
> Java Developer
> SouJava & JCP Member
> GitHub: https://github.com/Daniel-Dos
> Linkedin: www.linkedin.com/in/danieldiasjava
> Twitter: http://twitter.com/danieldiasjava
>
>
> Em seg, 24 de dez de 2018 às 21:28, David Blevins <[hidden email]
> >
> escreveu:
>
> > I say “game on” to any languages people want to contribute :)
> >
> > In fact, let the PRs fly. I’ll write the site logic this week.
> >
> > -David
> >
> > On Mon, Dec 24, 2018 at 2:45 PM Mohammed Aboullaite <
> > [hidden email]> wrote:
> >
> > > I think its a brilliant idea. it'll open the door for not only Spanish,
> > but
> > > other languages as well (I'm thinking of French as well).
> > >
> > >
> > >
> > > On Mon, Dec 24, 2018, 11:35 PM David Blevins <[hidden email]
> > > wrote:
> > >
> > > > I was talking with Hillmer on twitter about potentially translating
> > > > examples into Spanish.
> > > >
> > > > The idea is that we could potentially do examples and documentation
> in
> > > > Spanish.  Perhaps:
> > > >
> > > >  - http://tomee.apache.org/tomee-8.0/es/docs/
> > > >  - http://tomee.apache.org/tomee-8.0/es/ejemplos/
> > > >
> > > > First note is that how we organize the files in the git repo and how
> we
> > > > organize them on the website can be completely different.  We use the
> > > > following code to collect all the examples together and do various
> > things
> > > > to them:
> > > >
> > > >  -
> > > >
> > >
> >
> https://github.com/apache/tomee-site-generator/blob/master/src/main/java/org/apache/tomee/website/Examples.java#L42
> > > >
> > > > Right now it will do a copy and rename, for example:
> > > >
> > > >  -
> > > >
> > >
> >
> https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README.md
> > > >  - http://tomee.apache.org/tomee-8.0/examples/cdi-request-scope.html
> > > >
> > > > We could theoretically do something as simple as this:
> > > >
> > > >  -
> > > >
> > >
> >
> https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README_es.md
> > > >  -
> > http://tomee.apache.org/tomee-8.0/es/ejemplos/cdi-request-scope.html
> > > >
> > > > I.e. make a new file next to the original, then update our copying
> > logic
> > > > to put the prefix in the path.
> > > >
> > > >
> > > > Thoughts?
> > > >
> > > >
> > > > --
> > > > David Blevins
> > > > http://twitter.com/dblevins
> > > > http://www.tomitribe.com
> > > >
> > > >
> > >
> > --
> > Sent from my iPhone
> >
>
Reply | Threaded
Open this post in threaded view
|

Re: Ejemplos en Español

brunobat
Hi Carlos,

Just chose a few documents, create the jiras and let us know them.

Cheers!

Bruno Baptista
https://twitter.com/brunobat_


On 03/01/19 01:11, Carlos Chacín wrote:

> +1 please let me know how I can help
>
> On Mon, Dec 24, 2018, 8:24 PM Daniel Dias Dos Santos <
> [hidden email] wrote:
>
>> +1  :  )
>> --
>>
>> *Daniel Dias dos Santos*
>> Java Developer
>> SouJava & JCP Member
>> GitHub: https://github.com/Daniel-Dos
>> Linkedin: www.linkedin.com/in/danieldiasjava
>> Twitter: http://twitter.com/danieldiasjava
>>
>>
>> Em seg, 24 de dez de 2018 às 21:28, David Blevins <[hidden email]
>> escreveu:
>>
>>> I say “game on” to any languages people want to contribute :)
>>>
>>> In fact, let the PRs fly. I’ll write the site logic this week.
>>>
>>> -David
>>>
>>> On Mon, Dec 24, 2018 at 2:45 PM Mohammed Aboullaite <
>>> [hidden email]> wrote:
>>>
>>>> I think its a brilliant idea. it'll open the door for not only Spanish,
>>> but
>>>> other languages as well (I'm thinking of French as well).
>>>>
>>>>
>>>>
>>>> On Mon, Dec 24, 2018, 11:35 PM David Blevins <[hidden email]
>>>> wrote:
>>>>
>>>>> I was talking with Hillmer on twitter about potentially translating
>>>>> examples into Spanish.
>>>>>
>>>>> The idea is that we could potentially do examples and documentation
>> in
>>>>> Spanish.  Perhaps:
>>>>>
>>>>>   - http://tomee.apache.org/tomee-8.0/es/docs/
>>>>>   - http://tomee.apache.org/tomee-8.0/es/ejemplos/
>>>>>
>>>>> First note is that how we organize the files in the git repo and how
>> we
>>>>> organize them on the website can be completely different.  We use the
>>>>> following code to collect all the examples together and do various
>>> things
>>>>> to them:
>>>>>
>>>>>   -
>>>>>
>> https://github.com/apache/tomee-site-generator/blob/master/src/main/java/org/apache/tomee/website/Examples.java#L42
>>>>> Right now it will do a copy and rename, for example:
>>>>>
>>>>>   -
>>>>>
>> https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README.md
>>>>>   - http://tomee.apache.org/tomee-8.0/examples/cdi-request-scope.html
>>>>>
>>>>> We could theoretically do something as simple as this:
>>>>>
>>>>>   -
>>>>>
>> https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README_es.md
>>>>>   -
>>> http://tomee.apache.org/tomee-8.0/es/ejemplos/cdi-request-scope.html
>>>>> I.e. make a new file next to the original, then update our copying
>>> logic
>>>>> to put the prefix in the path.
>>>>>
>>>>>
>>>>> Thoughts?
>>>>>
>>>>>
>>>>> --
>>>>> David Blevins
>>>>> http://twitter.com/dblevins
>>>>> http://www.tomitribe.com
>>>>>
>>>>>
>>> --
>>> Sent from my iPhone
>>>
Reply | Threaded
Open this post in threaded view
|

Re: Ejemplos en Español

César Hernández Mendoza
Now that we have the main task (TomEE-2442), I created the first sub tast:
"Update tomee-site-generator to allow examples and docs
internationalization- [TOMEE-2444]"

Can some of the Jira admins please assign
https://issues.apache.org/jira/browse/TOMEE-2444 to me?
This will implement and validate David's proposal, if I make it work then
the door will be open to starting the translation marathon :)



El jue., 3 ene. 2019 a las 3:10, Bruno Baptista (<[hidden email]>)
escribió:

> Hi Carlos,
>
> Just chose a few documents, create the jiras and let us know them.
>
> Cheers!
>
> Bruno Baptista
> https://twitter.com/brunobat_
>
>
> On 03/01/19 01:11, Carlos Chacín wrote:
> > +1 please let me know how I can help
> >
> > On Mon, Dec 24, 2018, 8:24 PM Daniel Dias Dos Santos <
> > [hidden email] wrote:
> >
> >> +1  :  )
> >> --
> >>
> >> *Daniel Dias dos Santos*
> >> Java Developer
> >> SouJava & JCP Member
> >> GitHub: https://github.com/Daniel-Dos
> >> Linkedin: www.linkedin.com/in/danieldiasjava
> >> Twitter: http://twitter.com/danieldiasjava
> >>
> >>
> >> Em seg, 24 de dez de 2018 às 21:28, David Blevins <
> [hidden email]
> >> escreveu:
> >>
> >>> I say “game on” to any languages people want to contribute :)
> >>>
> >>> In fact, let the PRs fly. I’ll write the site logic this week.
> >>>
> >>> -David
> >>>
> >>> On Mon, Dec 24, 2018 at 2:45 PM Mohammed Aboullaite <
> >>> [hidden email]> wrote:
> >>>
> >>>> I think its a brilliant idea. it'll open the door for not only
> Spanish,
> >>> but
> >>>> other languages as well (I'm thinking of French as well).
> >>>>
> >>>>
> >>>>
> >>>> On Mon, Dec 24, 2018, 11:35 PM David Blevins <[hidden email]
> >>>> wrote:
> >>>>
> >>>>> I was talking with Hillmer on twitter about potentially translating
> >>>>> examples into Spanish.
> >>>>>
> >>>>> The idea is that we could potentially do examples and documentation
> >> in
> >>>>> Spanish.  Perhaps:
> >>>>>
> >>>>>   - http://tomee.apache.org/tomee-8.0/es/docs/
> >>>>>   - http://tomee.apache.org/tomee-8.0/es/ejemplos/
> >>>>>
> >>>>> First note is that how we organize the files in the git repo and how
> >> we
> >>>>> organize them on the website can be completely different.  We use the
> >>>>> following code to collect all the examples together and do various
> >>> things
> >>>>> to them:
> >>>>>
> >>>>>   -
> >>>>>
> >>
> https://github.com/apache/tomee-site-generator/blob/master/src/main/java/org/apache/tomee/website/Examples.java#L42
> >>>>> Right now it will do a copy and rename, for example:
> >>>>>
> >>>>>   -
> >>>>>
> >>
> https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README.md
> >>>>>   -
> http://tomee.apache.org/tomee-8.0/examples/cdi-request-scope.html
> >>>>>
> >>>>> We could theoretically do something as simple as this:
> >>>>>
> >>>>>   -
> >>>>>
> >>
> https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README_es.md
> >>>>>   -
> >>> http://tomee.apache.org/tomee-8.0/es/ejemplos/cdi-request-scope.html
> >>>>> I.e. make a new file next to the original, then update our copying
> >>> logic
> >>>>> to put the prefix in the path.
> >>>>>
> >>>>>
> >>>>> Thoughts?
> >>>>>
> >>>>>
> >>>>> --
> >>>>> David Blevins
> >>>>> http://twitter.com/dblevins
> >>>>> http://www.tomitribe.com
> >>>>>
> >>>>>
> >>> --
> >>> Sent from my iPhone
> >>>
>


--
Atentamente:
César Hernández Mendoza.
Reply | Threaded
Open this post in threaded view
|

Re: Ejemplos en Español

David Blevins-2

> On Jan 3, 2019, at 8:40 AM, César Hernández Mendoza <[hidden email]> wrote:
>
> Now that we have the main task (TomEE-2442), I created the first sub tast:
> "Update tomee-site-generator to allow examples and docs
> internationalization- [TOMEE-2444]"
>
> Can some of the Jira admins please assign
> https://issues.apache.org/jira/browse/TOMEE-2444 to me?

Assigned!

> This will implement and validate David's proposal, if I make it work then
> the door will be open to starting the translation marathon :)

I recommend we translate a few examples now so you have something to code against.

Great to see excitement behind this :)  It could be huge :)

-David


> El jue., 3 ene. 2019 a las 3:10, Bruno Baptista (<[hidden email]>)
> escribió:
>
>> Hi Carlos,
>>
>> Just chose a few documents, create the jiras and let us know them.
>>
>> Cheers!
>>
>> Bruno Baptista
>> https://twitter.com/brunobat_
>>
>>
>> On 03/01/19 01:11, Carlos Chacín wrote:
>>> +1 please let me know how I can help
>>>
>>> On Mon, Dec 24, 2018, 8:24 PM Daniel Dias Dos Santos <
>>> [hidden email] wrote:
>>>
>>>> +1  :  )
>>>> --
>>>>
>>>> *Daniel Dias dos Santos*
>>>> Java Developer
>>>> SouJava & JCP Member
>>>> GitHub: https://github.com/Daniel-Dos
>>>> Linkedin: www.linkedin.com/in/danieldiasjava
>>>> Twitter: http://twitter.com/danieldiasjava
>>>>
>>>>
>>>> Em seg, 24 de dez de 2018 às 21:28, David Blevins <
>> [hidden email]
>>>> escreveu:
>>>>
>>>>> I say “game on” to any languages people want to contribute :)
>>>>>
>>>>> In fact, let the PRs fly. I’ll write the site logic this week.
>>>>>
>>>>> -David
>>>>>
>>>>> On Mon, Dec 24, 2018 at 2:45 PM Mohammed Aboullaite <
>>>>> [hidden email]> wrote:
>>>>>
>>>>>> I think its a brilliant idea. it'll open the door for not only
>> Spanish,
>>>>> but
>>>>>> other languages as well (I'm thinking of French as well).
>>>>>>
>>>>>>
>>>>>>
>>>>>> On Mon, Dec 24, 2018, 11:35 PM David Blevins <[hidden email]
>>>>>> wrote:
>>>>>>
>>>>>>> I was talking with Hillmer on twitter about potentially translating
>>>>>>> examples into Spanish.
>>>>>>>
>>>>>>> The idea is that we could potentially do examples and documentation
>>>> in
>>>>>>> Spanish.  Perhaps:
>>>>>>>
>>>>>>>  - http://tomee.apache.org/tomee-8.0/es/docs/
>>>>>>>  - http://tomee.apache.org/tomee-8.0/es/ejemplos/
>>>>>>>
>>>>>>> First note is that how we organize the files in the git repo and how
>>>> we
>>>>>>> organize them on the website can be completely different.  We use the
>>>>>>> following code to collect all the examples together and do various
>>>>> things
>>>>>>> to them:
>>>>>>>
>>>>>>>  -
>>>>>>>
>>>>
>> https://github.com/apache/tomee-site-generator/blob/master/src/main/java/org/apache/tomee/website/Examples.java#L42
>>>>>>> Right now it will do a copy and rename, for example:
>>>>>>>
>>>>>>>  -
>>>>>>>
>>>>
>> https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README.md
>>>>>>>  -
>> http://tomee.apache.org/tomee-8.0/examples/cdi-request-scope.html
>>>>>>>
>>>>>>> We could theoretically do something as simple as this:
>>>>>>>
>>>>>>>  -
>>>>>>>
>>>>
>> https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README_es.md
>>>>>>>  -
>>>>> http://tomee.apache.org/tomee-8.0/es/ejemplos/cdi-request-scope.html
>>>>>>> I.e. make a new file next to the original, then update our copying
>>>>> logic
>>>>>>> to put the prefix in the path.
>>>>>>>
>>>>>>>
>>>>>>> Thoughts?
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> David Blevins
>>>>>>> http://twitter.com/dblevins
>>>>>>> http://www.tomitribe.com
>>>>>>>
>>>>>>>
>>>>> --
>>>>> Sent from my iPhone
>>>>>
>>
>
>
> --
> Atentamente:
> César Hernández Mendoza.

Reply | Threaded
Open this post in threaded view
|

Re: Ejemplos en Español

César Hernández Mendoza
Update:
My PR is still WIP. I identified a missing requirement: how we are going to
present the available languages for each Source.
After doing some mocks, I come up with this solution:

tomee-8.0 (latest)
    Documentation
    Examples [fr] [es]

When you click [fr] or [es], then the page for the translated examples
appears: http://localhost:8080/tomee-8.0/examples/es/ or
http://localhost:8080/tomee-8.0/examples/fr/
Keeping the link for `Examples` the default in English:
http://localhost:8080/tomee-8.0/examples/

The site automatically generates the /<language> structure based on the
suffix for the readme file:   README_<2LetterLanguage>.adoc

A video can clear out a lot of questions, you can check the video of the
current PR that I expect to finish on Monday next week. I think I'm very
close :)!
https://issues.apache.org/jira/browse/TOMEE-2444?focusedCommentId=16734742&page=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-16734742

El jue., 3 ene. 2019 a las 13:28, David Blevins (<[hidden email]>)
escribió:

>
> > On Jan 3, 2019, at 8:40 AM, César Hernández Mendoza <
> [hidden email]> wrote:
> >
> > Now that we have the main task (TomEE-2442), I created the first sub
> tast:
> > "Update tomee-site-generator to allow examples and docs
> > internationalization- [TOMEE-2444]"
> >
> > Can some of the Jira admins please assign
> > https://issues.apache.org/jira/browse/TOMEE-2444 to me?
>
> Assigned!
>
> > This will implement and validate David's proposal, if I make it work then
> > the door will be open to starting the translation marathon :)
>
> I recommend we translate a few examples now so you have something to code
> against.
>
> Great to see excitement behind this :)  It could be huge :)
>
> -David
>
>
> > El jue., 3 ene. 2019 a las 3:10, Bruno Baptista (<[hidden email]>)
> > escribió:
> >
> >> Hi Carlos,
> >>
> >> Just chose a few documents, create the jiras and let us know them.
> >>
> >> Cheers!
> >>
> >> Bruno Baptista
> >> https://twitter.com/brunobat_
> >>
> >>
> >> On 03/01/19 01:11, Carlos Chacín wrote:
> >>> +1 please let me know how I can help
> >>>
> >>> On Mon, Dec 24, 2018, 8:24 PM Daniel Dias Dos Santos <
> >>> [hidden email] wrote:
> >>>
> >>>> +1  :  )
> >>>> --
> >>>>
> >>>> *Daniel Dias dos Santos*
> >>>> Java Developer
> >>>> SouJava & JCP Member
> >>>> GitHub: https://github.com/Daniel-Dos
> >>>> Linkedin: www.linkedin.com/in/danieldiasjava
> >>>> Twitter: http://twitter.com/danieldiasjava
> >>>>
> >>>>
> >>>> Em seg, 24 de dez de 2018 às 21:28, David Blevins <
> >> [hidden email]
> >>>> escreveu:
> >>>>
> >>>>> I say “game on” to any languages people want to contribute :)
> >>>>>
> >>>>> In fact, let the PRs fly. I’ll write the site logic this week.
> >>>>>
> >>>>> -David
> >>>>>
> >>>>> On Mon, Dec 24, 2018 at 2:45 PM Mohammed Aboullaite <
> >>>>> [hidden email]> wrote:
> >>>>>
> >>>>>> I think its a brilliant idea. it'll open the door for not only
> >> Spanish,
> >>>>> but
> >>>>>> other languages as well (I'm thinking of French as well).
> >>>>>>
> >>>>>>
> >>>>>>
> >>>>>> On Mon, Dec 24, 2018, 11:35 PM David Blevins <
> [hidden email]
> >>>>>> wrote:
> >>>>>>
> >>>>>>> I was talking with Hillmer on twitter about potentially translating
> >>>>>>> examples into Spanish.
> >>>>>>>
> >>>>>>> The idea is that we could potentially do examples and documentation
> >>>> in
> >>>>>>> Spanish.  Perhaps:
> >>>>>>>
> >>>>>>>  - http://tomee.apache.org/tomee-8.0/es/docs/
> >>>>>>>  - http://tomee.apache.org/tomee-8.0/es/ejemplos/
> >>>>>>>
> >>>>>>> First note is that how we organize the files in the git repo and
> how
> >>>> we
> >>>>>>> organize them on the website can be completely different.  We use
> the
> >>>>>>> following code to collect all the examples together and do various
> >>>>> things
> >>>>>>> to them:
> >>>>>>>
> >>>>>>>  -
> >>>>>>>
> >>>>
> >>
> https://github.com/apache/tomee-site-generator/blob/master/src/main/java/org/apache/tomee/website/Examples.java#L42
> >>>>>>> Right now it will do a copy and rename, for example:
> >>>>>>>
> >>>>>>>  -
> >>>>>>>
> >>>>
> >>
> https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README.md
> >>>>>>>  -
> >> http://tomee.apache.org/tomee-8.0/examples/cdi-request-scope.html
> >>>>>>>
> >>>>>>> We could theoretically do something as simple as this:
> >>>>>>>
> >>>>>>>  -
> >>>>>>>
> >>>>
> >>
> https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README_es.md
> >>>>>>>  -
> >>>>> http://tomee.apache.org/tomee-8.0/es/ejemplos/cdi-request-scope.html
> >>>>>>> I.e. make a new file next to the original, then update our copying
> >>>>> logic
> >>>>>>> to put the prefix in the path.
> >>>>>>>
> >>>>>>>
> >>>>>>> Thoughts?
> >>>>>>>
> >>>>>>>
> >>>>>>> --
> >>>>>>> David Blevins
> >>>>>>> http://twitter.com/dblevins
> >>>>>>> http://www.tomitribe.com
> >>>>>>>
> >>>>>>>
> >>>>> --
> >>>>> Sent from my iPhone
> >>>>>
> >>
> >
> >
> > --
> > Atentamente:
> > César Hernández Mendoza.
>
>

--
Atentamente:
César Hernández Mendoza.
Reply | Threaded
Open this post in threaded view
|

Re: Ejemplos en Español

César Hernández Mendoza
Hi,

I rebase the PR with the latest master and did code clean up.
The PR for https://issues.apache.org/jira/browse/TOMEE-2444 is ready for
review.
I included in the PR the instructions to check the feature:
https://github.com/apache/tomee-site-generator/pull/16

To review this PR you need:

1. build the project: `tomee-site-generator$ mvn clean install`
2. Choose any example like for example
`tomee-site-generator/repos/tomee-8.0/examples/mp-config-example/` and
create a readme file with a suffix that represents the translation for the
readme. For example: ` README_fr.adoc `.
3. Build and run the project: `tomee-site-generator$ mvn  clean compile
-Djbake.http=true`
4. The project should show in `http://localhost:8080/docs.html` the [fr]
link to the examples in French.


El vie., 4 ene. 2019 a las 20:47, César Hernández Mendoza (<
[hidden email]>) escribió:

> Update:
> My PR is still WIP. I identified a missing requirement: how we are going
> to present the available languages for each Source.
> After doing some mocks, I come up with this solution:
>
> tomee-8.0 (latest)
>     Documentation
>     Examples [fr] [es]
>
> When you click [fr] or [es], then the page for the translated examples
> appears: http://localhost:8080/tomee-8.0/examples/es/ or
> http://localhost:8080/tomee-8.0/examples/fr/
> Keeping the link for `Examples` the default in English:
> http://localhost:8080/tomee-8.0/examples/
>
> The site automatically generates the /<language> structure based on the
> suffix for the readme file:   README_<2LetterLanguage>.adoc
>
> A video can clear out a lot of questions, you can check the video of the
> current PR that I expect to finish on Monday next week. I think I'm very
> close :)!
>
> https://issues.apache.org/jira/browse/TOMEE-2444?focusedCommentId=16734742&page=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-16734742
>
> El jue., 3 ene. 2019 a las 13:28, David Blevins (<[hidden email]>)
> escribió:
>
>>
>> > On Jan 3, 2019, at 8:40 AM, César Hernández Mendoza <
>> [hidden email]> wrote:
>> >
>> > Now that we have the main task (TomEE-2442), I created the first sub
>> tast:
>> > "Update tomee-site-generator to allow examples and docs
>> > internationalization- [TOMEE-2444]"
>> >
>> > Can some of the Jira admins please assign
>> > https://issues.apache.org/jira/browse/TOMEE-2444 to me?
>>
>> Assigned!
>>
>> > This will implement and validate David's proposal, if I make it work
>> then
>> > the door will be open to starting the translation marathon :)
>>
>> I recommend we translate a few examples now so you have something to code
>> against.
>>
>> Great to see excitement behind this :)  It could be huge :)
>>
>> -David
>>
>>
>> > El jue., 3 ene. 2019 a las 3:10, Bruno Baptista (<[hidden email]>)
>> > escribió:
>> >
>> >> Hi Carlos,
>> >>
>> >> Just chose a few documents, create the jiras and let us know them.
>> >>
>> >> Cheers!
>> >>
>> >> Bruno Baptista
>> >> https://twitter.com/brunobat_
>> >>
>> >>
>> >> On 03/01/19 01:11, Carlos Chacín wrote:
>> >>> +1 please let me know how I can help
>> >>>
>> >>> On Mon, Dec 24, 2018, 8:24 PM Daniel Dias Dos Santos <
>> >>> [hidden email] wrote:
>> >>>
>> >>>> +1  :  )
>> >>>> --
>> >>>>
>> >>>> *Daniel Dias dos Santos*
>> >>>> Java Developer
>> >>>> SouJava & JCP Member
>> >>>> GitHub: https://github.com/Daniel-Dos
>> >>>> Linkedin: www.linkedin.com/in/danieldiasjava
>> >>>> Twitter: http://twitter.com/danieldiasjava
>> >>>>
>> >>>>
>> >>>> Em seg, 24 de dez de 2018 às 21:28, David Blevins <
>> >> [hidden email]
>> >>>> escreveu:
>> >>>>
>> >>>>> I say “game on” to any languages people want to contribute :)
>> >>>>>
>> >>>>> In fact, let the PRs fly. I’ll write the site logic this week.
>> >>>>>
>> >>>>> -David
>> >>>>>
>> >>>>> On Mon, Dec 24, 2018 at 2:45 PM Mohammed Aboullaite <
>> >>>>> [hidden email]> wrote:
>> >>>>>
>> >>>>>> I think its a brilliant idea. it'll open the door for not only
>> >> Spanish,
>> >>>>> but
>> >>>>>> other languages as well (I'm thinking of French as well).
>> >>>>>>
>> >>>>>>
>> >>>>>>
>> >>>>>> On Mon, Dec 24, 2018, 11:35 PM David Blevins <
>> [hidden email]
>> >>>>>> wrote:
>> >>>>>>
>> >>>>>>> I was talking with Hillmer on twitter about potentially
>> translating
>> >>>>>>> examples into Spanish.
>> >>>>>>>
>> >>>>>>> The idea is that we could potentially do examples and
>> documentation
>> >>>> in
>> >>>>>>> Spanish.  Perhaps:
>> >>>>>>>
>> >>>>>>>  - http://tomee.apache.org/tomee-8.0/es/docs/
>> >>>>>>>  - http://tomee.apache.org/tomee-8.0/es/ejemplos/
>> >>>>>>>
>> >>>>>>> First note is that how we organize the files in the git repo and
>> how
>> >>>> we
>> >>>>>>> organize them on the website can be completely different.  We use
>> the
>> >>>>>>> following code to collect all the examples together and do various
>> >>>>> things
>> >>>>>>> to them:
>> >>>>>>>
>> >>>>>>>  -
>> >>>>>>>
>> >>>>
>> >>
>> https://github.com/apache/tomee-site-generator/blob/master/src/main/java/org/apache/tomee/website/Examples.java#L42
>> >>>>>>> Right now it will do a copy and rename, for example:
>> >>>>>>>
>> >>>>>>>  -
>> >>>>>>>
>> >>>>
>> >>
>> https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README.md
>> >>>>>>>  -
>> >> http://tomee.apache.org/tomee-8.0/examples/cdi-request-scope.html
>> >>>>>>>
>> >>>>>>> We could theoretically do something as simple as this:
>> >>>>>>>
>> >>>>>>>  -
>> >>>>>>>
>> >>>>
>> >>
>> https://github.com/apache/tomee/blob/master/examples/cdi-request-scope/README_es.md
>> >>>>>>>  -
>> >>>>>
>> http://tomee.apache.org/tomee-8.0/es/ejemplos/cdi-request-scope.html
>> >>>>>>> I.e. make a new file next to the original, then update our copying
>> >>>>> logic
>> >>>>>>> to put the prefix in the path.
>> >>>>>>>
>> >>>>>>>
>> >>>>>>> Thoughts?
>> >>>>>>>
>> >>>>>>>
>> >>>>>>> --
>> >>>>>>> David Blevins
>> >>>>>>> http://twitter.com/dblevins
>> >>>>>>> http://www.tomitribe.com
>> >>>>>>>
>> >>>>>>>
>> >>>>> --
>> >>>>> Sent from my iPhone
>> >>>>>
>> >>
>> >
>> >
>> > --
>> > Atentamente:
>> > César Hernández Mendoza.
>>
>>
>
> --
> Atentamente:
> César Hernández Mendoza.
>


--
Atentamente:
César Hernández Mendoza.
Reply | Threaded
Open this post in threaded view
|

Re: Ejemplos en Español

David Blevins-2
In reply to this post by César Hernández Mendoza
> On Jan 4, 2019, at 6:47 PM, César Hernández Mendoza <[hidden email]> wrote:
>
> When you click [fr] or [es], then the page for the translated examples
> appears: http://localhost:8080/tomee-8.0/examples/es/ or
> http://localhost:8080/tomee-8.0/examples/fr/
> Keeping the link for `Examples` the default in English:
> http://localhost:8080/tomee-8.0/examples/

My perspective is we should switch this around from:

 - http://localhost:8080/tomee-8.0/examples/fr/

To:

 - http://localhost:8080/tomee-8.0/fr/examples/

Some reasons:

 - this approach works for more than examples and can work for other documentation as well
 - we could potentially use non-english names in the path instead of always the english "examples"

So both combined could look like this:

 - http://localhost:8080/tomee-8.0/es/index.html # this would be all resources in es
 - http://localhost:8080/tomee-8.0/es/ejemplos/<something>.html
 - http://localhost:8080/tomee-8.0/es/docs/<foobar>.html

This would grow better over time IMO.

Thoughts?

Note we can still take the PR as-is ; things can easily evolve in the codebase.


-David


Reply | Threaded
Open this post in threaded view
|

Re: Ejemplos en Español

brunobat
+1

Bruno Baptista
https://twitter.com/brunobat_


On 08/01/19 19:22, David Blevins wrote:
> My perspective is we should switch this around from:
>
>   -http://localhost:8080/tomee-8.0/examples/fr/
>
> To:
>
>   -http://localhost:8080/tomee-8.0/fr/examples/
Reply | Threaded
Open this post in threaded view
|

Re: Ejemplos en Español

cchacin
+1

On Tue, Jan 8, 2019 at 12:00 PM Bruno Baptista <[hidden email]> wrote:

> +1
>
> Bruno Baptista
> https://twitter.com/brunobat_
>
>
> On 08/01/19 19:22, David Blevins wrote:
> > My perspective is we should switch this around from:
> >
> >   -http://localhost:8080/tomee-8.0/examples/fr/
> >
> > To:
> >
> >   -http://localhost:8080/tomee-8.0/fr/examples/
>


--
*Carlos Chacin*
Software Developer Engineering
Reply | Threaded
Open this post in threaded view
|

Re: Ejemplos en Español

César Hernández Mendoza
In reply to this post by David Blevins-2
Thank you for the feedback. I have one question regarding the navigation:

Currently from the homepage, one can go to http://tomee.apache.org/docs.html
by clicking the Documentation button.
The resulting page has the following structure:


tomee-8.0 (latest)
 Documentation
 Examples [es]
 Javadoc

tomee-7.1
 Examples [es] [fr]
 Javadoc
...

 By changing to  http://localhost:8080/tomee-8.0/fr/examples/ approach,
does the Documentation button should show the languages available as a list
instead of the list described above?
* English
* Spanish
* French




El mar., 8 ene. 2019 a las 13:29, David Blevins (<[hidden email]>)
escribió:

> > On Jan 4, 2019, at 6:47 PM, César Hernández Mendoza <
> [hidden email]> wrote:
> >
> > When you click [fr] or [es], then the page for the translated examples
> > appears: http://localhost:8080/tomee-8.0/examples/es/ or
> > http://localhost:8080/tomee-8.0/examples/fr/
> > Keeping the link for `Examples` the default in English:
> > http://localhost:8080/tomee-8.0/examples/
>
> My perspective is we should switch this around from:
>
>  - http://localhost:8080/tomee-8.0/examples/fr/
>
> To:
>
>  - http://localhost:8080/tomee-8.0/fr/examples/
>
> Some reasons:
>
>  - this approach works for more than examples and can work for other
> documentation as well
>  - we could potentially use non-english names in the path instead of
> always the english "examples"
>
> So both combined could look like this:
>
>  - http://localhost:8080/tomee-8.0/es/index.html # this would be all
> resources in es
>  - http://localhost:8080/tomee-8.0/es/ejemplos/<something>.html
>  - http://localhost:8080/tomee-8.0/es/docs/<foobar>.html
>
> This would grow better over time IMO.
>
> Thoughts?
>
> Note we can still take the PR as-is ; things can easily evolve in the
> codebase.
>
>
> -David
>
>
>

--
Atentamente:
César Hernández Mendoza.
Reply | Threaded
Open this post in threaded view
|

Re: Ejemplos en Español

David Blevins-2
> On Jan 8, 2019, at 12:32 PM, César Hernández Mendoza <[hidden email]> wrote:
>
> tomee-8.0 (latest)
> Documentation
> Examples [es]
> Javadoc
>
> tomee-7.1
> Examples [es] [fr]
> Javadoc

We could still do that regardless of the url pattern change.  There's a little bit of jumping already happening on the main /docs.html page.  Particularly:

 - http://tomee.apache.org/docs.html           ... links to
 - http://tomee.apache.org/tomee-8.0/docs/     ... here and skips over
 - http://tomee.apache.org/tomee-8.0/          ... this page which does exist

The only way to get to "tomee-8.0/index.html" is via URL hack.  But it's there in case we want to point people to it.  If we wanted tot add breadcrumbs, we're ready.

There could and should be a "tomee-8.0/es/index.html" page.

I haven't looked at the PR since this weekend, but one approach might be to break up this method https://github.com/apache/tomee-site-generator/blob/master/src/main/java/org/apache/tomee/website/Sources.java#L117

This is pseudo code, but something a little like this:

    public void prepare() {
        // copy the non-version specific stuff over
        try {
            IO.copyDirectory(mainSource, jbake);
        } catch (IOException e) {
            throw new RuntimeException(e);
        }

        // download all the external repos
        sources.stream()
                .flatMap(source -> source.getRelated().stream())
                .peek(source -> source.setDir(new File(repos, source.getName())))
                .forEach(Repos::download);

        // download all our repos and process javadoc
        final Javadocs javadocs = new Javadocs(this);
        sources.stream()
                .peek(source -> source.setDir(new File(repos, source.getName())))
                .peek(Repos::download)
                .forEach(javadocs::prepare);
        ;

        // for each source, collect the extensions and process them
        // each gets its own identical layout
        // perhaps empty string "" implies english
        for (Source source : sources) {
            for (String lang : source.findLanguages()) {

                final Docs docs = new Docs(this, lang);
                final Examples examples = new Examples(this, lang);
                final VersionIndex versionIndex = new VersionIndex(this, lang);

                // this logic now knows what language it needs to look for and collect and process
                sources.stream()
                        .peek(docs::prepare)
                        .peek(examples::prepare)
                        .peek(versionIndex::prepare)
                        .forEach(Sources::done);
            }
        }

        // create the big magical index across all projects, versions and languages
        // we can try to keep it on one page for as long as possible
        // it will eventually get too big, but we're not there yet

        VersionsIndex.prepare(this);
    }

Then we make sure anything we add in that second set of loops always handles internationalization.  Now it's docs and examples.  Tomorrow it could include presentations, video links, who knows.

I'm sure that second set of loops could be done with Streams.  I don't know that I could type that into an email window with confidence :)


-David

12