You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Mirko Friedenhagen <mf...@gmail.com> on 2012/04/24 20:09:07 UTC

How to get an URL encoded version of a property?

Hello,

say I want to reuse some POM or system property as parameter in another
place in the POM but need it URL encoded. Does anyone know a Maven "magic"
to achieve this?

Programming a plugin to encode a given list of properties  and provide them
under a different name seems no biggy, but I would like to know if there
are other, better or easier options :-D .

Regards Mirko
-- 
Sent from my phone
http://illegalstateexception.blogspot.com
http://github.com/mfriedenhagen/
https://bitbucket.org/mfriedenhagen/

Re: How to get an URL encoded version of a property?

Posted by Mirko Friedenhagen <mf...@gmail.com>.
Hello Jörg,

thanks for your suggestion. Though I always feel a litte bit like cheating
when using ant inside of Maven ;-) .

Regards Mirko
-- 
Sent from my phone
http://illegalstateexception.blogspot.com
http://github.com/mfriedenhagen/
https://bitbucket.org/mfriedenhagen/
On Apr 25, 2012 11:46 PM, "Jörg Hohwiller" <jo...@j-hohwiller.de> wrote:

> Hi Mirko,
>
> you do not have to write a plugin:
> http://ant-contrib.sourceforge.net/tasks/tasks/urlencode.html
>
> http://maven.apache.org/plugins/maven-antrun-plugin/
>
> Cheers
>  Jörg
>
> > On 04/24/2012 08:09 PM, Mirko Friedenhagen wrote:
> >> Hello,
> >
> > Hi Mirko,
> >
> >>
> >> say I want to reuse some POM or system property as parameter in another
> >> place in the POM but need it URL encoded. Does anyone know a Maven
> "magic"
> >> to achieve this?
> >>
> >> Programming a plugin to encode a given list of properties  and provide
> them
> >> under a different name seems no biggy, but I would like to know if there
> >> are other, better or easier options :-D .
> >
> > I also do not know any other way, but I might be missing something (e.g.
> new
> > features invented in m3).
> > Compared to jelly hacking in m1 I prefer writing a plugin though...
> >
> >>
> >> Regards Mirko
> >
> > Regards Jörg
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> > For additional commands, e-mail: users-help@maven.apache.org
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

Re: How to get an URL encoded version of a property?

Posted by Jörg Hohwiller <jo...@j-hohwiller.de>.
Hi Mirko,

you do not have to write a plugin:
http://ant-contrib.sourceforge.net/tasks/tasks/urlencode.html

http://maven.apache.org/plugins/maven-antrun-plugin/

Cheers
  Jörg

> On 04/24/2012 08:09 PM, Mirko Friedenhagen wrote:
>> Hello,
> 
> Hi Mirko,
> 
>>
>> say I want to reuse some POM or system property as parameter in another
>> place in the POM but need it URL encoded. Does anyone know a Maven "magic"
>> to achieve this?
>>
>> Programming a plugin to encode a given list of properties  and provide them
>> under a different name seems no biggy, but I would like to know if there
>> are other, better or easier options :-D .
> 
> I also do not know any other way, but I might be missing something (e.g. new
> features invented in m3).
> Compared to jelly hacking in m1 I prefer writing a plugin though...
> 
>>
>> Regards Mirko
> 
> Regards Jörg
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
> 


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


Re: How to get an URL encoded version of a property?

Posted by Jörg Hohwiller <jo...@j-hohwiller.de>.
On 04/24/2012 08:09 PM, Mirko Friedenhagen wrote:
> Hello,

Hi Mirko,

> 
> say I want to reuse some POM or system property as parameter in another
> place in the POM but need it URL encoded. Does anyone know a Maven "magic"
> to achieve this?
> 
> Programming a plugin to encode a given list of properties  and provide them
> under a different name seems no biggy, but I would like to know if there
> are other, better or easier options :-D .

I also do not know any other way, but I might be missing something (e.g. new
features invented in m3).
Compared to jelly hacking in m1 I prefer writing a plugin though...

> 
> Regards Mirko

Regards Jörg

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