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 (< cesargu...@gmail.com>) 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 (<david.blev...@gmail.com>) > escribió: > >> >> > On Jan 3, 2019, at 8:40 AM, César Hernández Mendoza < >> cesargu...@gmail.com> 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 (<bruno...@gmail.com>) >> > 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 < >> >>> daniel.dias.analist...@gmail.com 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 < >> >> david.blev...@gmail.com >> >>>> 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 < >> >>>>> aboullaite.moham...@gmail.com> 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 < >> david.blev...@gmail.com >> >>>>>> 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.