You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by Tom Norton <to...@gmail.com> on 2013/07/31 17:44:52 UTC

Wicket Content Parameters

We just received our content back from our translators.  They translated
everything correctly for our velocity templates.  However, when they
translated our wicket content, they also translated the parameters (one
translator even replaced the curly braces with parentheses).

Does anyone know it it's possible to use the ${...} syntax for content
parameters instead of {...}?  I ask because most translators already know
to steer clear of the ${...} syntax, since it's the de facto syntax for
parameters embedded into strings.

Thanks,
Tom

Re: Wicket Content Parameters

Posted by Cedric Gatay <ga...@gmail.com>.
Hi there, I finally open sourced the tool and added a few options as my
team requested internally : failing build if key count mismatch
(overridable via a property) and outputting empty property values to the
console while building.

You can find it here :
https://github.com/code-troopers/merge-properties-maven-plugin
@Paul, feel free to fork, improve, and so on...

Regards,

__
Cedric Gatay (@Cedric_Gatay <http://twitter.com/Cedric_Gatay>)
http://code-troopers.com | http://www.bloggure.info | http://cedric.gatay.fr


On Wed, Jul 31, 2013 at 7:39 PM, Paul Bors <pa...@bors.ws> wrote:

> I won't mind taking yours and adding my tests to it with an option to fail
> the build.
>
> I like failing the build to grab people's attention and also generating an
> e-mail report so we all know what's missing :)
>
> ~ Thank you,
>   Paul Bors
>
> -----Original Message-----
> From: Cedric Gatay [mailto:gatay.c@gmail.com]
> Sent: Wednesday, July 31, 2013 1:36 PM
> To: users@wicket.apache.org
> Subject: Re: Wicket Content Parameters
>
> We have a custom maven plugin aggregating multiple properties file into
> one per language. It checks and display (does not fail the build) if the
> number of keys is different. I will try to see if it can be open sourced
> soon if someone is interested in it.
>
> __
> Cedric Gatay (@Cedric_Gatay <http://twitter.com/Cedric_Gatay>)
> http://code-troopers.com | http://www.bloggure.info |
> http://cedric.gatay.fr
>
>
> On Wed, Jul 31, 2013 at 5:59 PM, Paul Bors <pa...@bors.ws> wrote:
>
> > We have unit tests that load the master lang pack (the development
> > one) and compare it key by key to all of the other language packs making
> sure that:
> > * It has all the necessary keys
> > * Parameters in values are not missing
> > * All values are translated (with different exceptions per lang pack)
> > Etc.
> >
> > It would be nice if such a tool existed as part of the core wicket app
> > or extensions but it really depends on how your app maintains them.
> > For example, we choose to maintain a single lang pack in a huge file
> > in XML format to make it easier to pass it on to the translators
> > instead of using many smaller files per page or panel.
> >
> > ~ Thank you,
> >   Paul Bors
> >
> > -----Original Message-----
> > From: Tom Norton [mailto:tomwnorton.mailing.lists@gmail.com]
> > Sent: Wednesday, July 31, 2013 11:45 AM
> > To: users@wicket.apache.org
> > Subject: Wicket Content Parameters
> >
> > We just received our content back from our translators.  They
> > translated everything correctly for our velocity templates.  However,
> > when they translated our wicket content, they also translated the
> > parameters (one translator even replaced the curly braces with
> parentheses).
> >
> > Does anyone know it it's possible to use the ${...} syntax for content
> > parameters instead of {...}?  I ask because most translators already
> > know to steer clear of the ${...} syntax, since it's the de facto
> > syntax for parameters embedded into strings.
> >
> > Thanks,
> > Tom
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> > For additional commands, e-mail: users-help@wicket.apache.org
> >
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>

RE: Wicket Content Parameters

Posted by Paul Bors <pa...@bors.ws>.
I won't mind taking yours and adding my tests to it with an option to fail the build.

I like failing the build to grab people's attention and also generating an e-mail report so we all know what's missing :)

~ Thank you,
  Paul Bors

-----Original Message-----
From: Cedric Gatay [mailto:gatay.c@gmail.com] 
Sent: Wednesday, July 31, 2013 1:36 PM
To: users@wicket.apache.org
Subject: Re: Wicket Content Parameters

We have a custom maven plugin aggregating multiple properties file into one per language. It checks and display (does not fail the build) if the number of keys is different. I will try to see if it can be open sourced soon if someone is interested in it.

__
Cedric Gatay (@Cedric_Gatay <http://twitter.com/Cedric_Gatay>)
http://code-troopers.com | http://www.bloggure.info | http://cedric.gatay.fr


On Wed, Jul 31, 2013 at 5:59 PM, Paul Bors <pa...@bors.ws> wrote:

> We have unit tests that load the master lang pack (the development 
> one) and compare it key by key to all of the other language packs making sure that:
> * It has all the necessary keys
> * Parameters in values are not missing
> * All values are translated (with different exceptions per lang pack) 
> Etc.
>
> It would be nice if such a tool existed as part of the core wicket app 
> or extensions but it really depends on how your app maintains them. 
> For example, we choose to maintain a single lang pack in a huge file 
> in XML format to make it easier to pass it on to the translators 
> instead of using many smaller files per page or panel.
>
> ~ Thank you,
>   Paul Bors
>
> -----Original Message-----
> From: Tom Norton [mailto:tomwnorton.mailing.lists@gmail.com]
> Sent: Wednesday, July 31, 2013 11:45 AM
> To: users@wicket.apache.org
> Subject: Wicket Content Parameters
>
> We just received our content back from our translators.  They 
> translated everything correctly for our velocity templates.  However, 
> when they translated our wicket content, they also translated the 
> parameters (one translator even replaced the curly braces with parentheses).
>
> Does anyone know it it's possible to use the ${...} syntax for content 
> parameters instead of {...}?  I ask because most translators already 
> know to steer clear of the ${...} syntax, since it's the de facto 
> syntax for parameters embedded into strings.
>
> Thanks,
> Tom
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: Wicket Content Parameters

Posted by Cedric Gatay <ga...@gmail.com>.
We have a custom maven plugin aggregating multiple properties file into one
per language. It checks and display (does not fail the build) if the number
of keys is different. I will try to see if it can be open sourced soon if
someone is interested in it.

__
Cedric Gatay (@Cedric_Gatay <http://twitter.com/Cedric_Gatay>)
http://code-troopers.com | http://www.bloggure.info | http://cedric.gatay.fr


On Wed, Jul 31, 2013 at 5:59 PM, Paul Bors <pa...@bors.ws> wrote:

> We have unit tests that load the master lang pack (the development one) and
> compare it key by key to all of the other language packs making sure that:
> * It has all the necessary keys
> * Parameters in values are not missing
> * All values are translated (with different exceptions per lang pack)
> Etc.
>
> It would be nice if such a tool existed as part of the core wicket app or
> extensions but it really depends on how your app maintains them. For
> example, we choose to maintain a single lang pack in a huge file in XML
> format to make it easier to pass it on to the translators instead of using
> many smaller files per page or panel.
>
> ~ Thank you,
>   Paul Bors
>
> -----Original Message-----
> From: Tom Norton [mailto:tomwnorton.mailing.lists@gmail.com]
> Sent: Wednesday, July 31, 2013 11:45 AM
> To: users@wicket.apache.org
> Subject: Wicket Content Parameters
>
> We just received our content back from our translators.  They translated
> everything correctly for our velocity templates.  However, when they
> translated our wicket content, they also translated the parameters (one
> translator even replaced the curly braces with parentheses).
>
> Does anyone know it it's possible to use the ${...} syntax for content
> parameters instead of {...}?  I ask because most translators already know
> to
> steer clear of the ${...} syntax, since it's the de facto syntax for
> parameters embedded into strings.
>
> Thanks,
> Tom
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>

RE: Wicket Content Parameters

Posted by Paul Bors <pa...@bors.ws>.
We have unit tests that load the master lang pack (the development one) and
compare it key by key to all of the other language packs making sure that:
* It has all the necessary keys
* Parameters in values are not missing
* All values are translated (with different exceptions per lang pack)
Etc.

It would be nice if such a tool existed as part of the core wicket app or
extensions but it really depends on how your app maintains them. For
example, we choose to maintain a single lang pack in a huge file in XML
format to make it easier to pass it on to the translators instead of using
many smaller files per page or panel.

~ Thank you,
  Paul Bors

-----Original Message-----
From: Tom Norton [mailto:tomwnorton.mailing.lists@gmail.com] 
Sent: Wednesday, July 31, 2013 11:45 AM
To: users@wicket.apache.org
Subject: Wicket Content Parameters

We just received our content back from our translators.  They translated
everything correctly for our velocity templates.  However, when they
translated our wicket content, they also translated the parameters (one
translator even replaced the curly braces with parentheses).

Does anyone know it it's possible to use the ${...} syntax for content
parameters instead of {...}?  I ask because most translators already know to
steer clear of the ${...} syntax, since it's the de facto syntax for
parameters embedded into strings.

Thanks,
Tom


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org