You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Jane Young <Ja...@Sun.COM> on 2009/07/16 20:04:00 UTC

escape ${some-value}

Hi Maven Gurus,

Is there a way to treat the literal value of ${foobar} instead of a 
property?
For example I want to be able to put an entry in the manifest using the 
Maven jar plugin.  The entry contains the value ${installRoot} but since 
there is no property associated with this, Maven converts it to 
"null".    In other words, is there a way that I can escape the 
expression ${..}?


Thanks in advance!
Jane

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


Re: escape ${some-value}

Posted by Jane Young <Ja...@Sun.COM>.
Thanks for all the help.

$${some-value} works.

Jane


Benson Margulies wrote:
> <properties>
>  <dollar>$</dollar>
> <bloop>{bloop}</bloop>
> <dollar.bloop>${dollar}${bloop}</dollar.bloop>
> </properties>
>
> On Thu, Jul 16, 2009 at 5:04 PM, David C. Hicks<dh...@i-hicks.org> wrote:
>   
>> You can configure other directories to be considered for filtering.  I'm
>> not familiar with configuring the JAR plugin to add entries to the
>> Manifest, though.  So, I'd be out of place trying to offer any advice on
>> that.
>>
>> Jane Young wrote:
>>     
>>> Hi David,
>>>
>>> Thanks for responding.
>>> Looks like  "escaping" works only in filtering resources, not in the
>>> pom.xml.
>>>
>>> One workaround is to create the manifest file in src/main/resources
>>> and use filtering to filter the entries.
>>>
>>> Other alternatives?
>>>
>>> Thanks,
>>> Jane
>>>
>>>       
>> ---------------------------------------------------------------------
>> 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: escape ${some-value}

Posted by Benson Margulies <bi...@gmail.com>.
<properties>
 <dollar>$</dollar>
<bloop>{bloop}</bloop>
<dollar.bloop>${dollar}${bloop}</dollar.bloop>
</properties>

On Thu, Jul 16, 2009 at 5:04 PM, David C. Hicks<dh...@i-hicks.org> wrote:
> You can configure other directories to be considered for filtering.  I'm
> not familiar with configuring the JAR plugin to add entries to the
> Manifest, though.  So, I'd be out of place trying to offer any advice on
> that.
>
> Jane Young wrote:
>> Hi David,
>>
>> Thanks for responding.
>> Looks like  "escaping" works only in filtering resources, not in the
>> pom.xml.
>>
>> One workaround is to create the manifest file in src/main/resources
>> and use filtering to filter the entries.
>>
>> Other alternatives?
>>
>> Thanks,
>> Jane
>>
>
> ---------------------------------------------------------------------
> 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: escape ${some-value}

Posted by "David C. Hicks" <dh...@i-hicks.org>.
You can configure other directories to be considered for filtering.  I'm
not familiar with configuring the JAR plugin to add entries to the
Manifest, though.  So, I'd be out of place trying to offer any advice on
that.

Jane Young wrote:
> Hi David,
>
> Thanks for responding.
> Looks like  "escaping" works only in filtering resources, not in the
> pom.xml.
>
> One workaround is to create the manifest file in src/main/resources
> and use filtering to filter the entries.
>
> Other alternatives?
>
> Thanks,
> Jane
>

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


Re: escape ${some-value}

Posted by Jane Young <Ja...@Sun.COM>.
Hi David,

Thanks for responding.
Looks like  "escaping" works only in filtering resources, not in the 
pom.xml.

One workaround is to create the manifest file in src/main/resources and 
use filtering to filter the entries.

Other alternatives?

Thanks,
Jane




David C. Hicks wrote:
> Hi Jane,
>
> I just happened to be looking for other information about "escaping"
> when I saw your question. Looks like you can use:
>
>     \${foobar}
>
> To cause the literal to be used. Here's a link to the page where I found
> this: http://maven.apache.org/shared/maven-filtering/
> Dave
>
>
> Jane Young wrote:
>   
>> Hi Maven Gurus,
>>
>> Is there a way to treat the literal value of ${foobar} instead of a
>> property?
>> For example I want to be able to put an entry in the manifest using
>> the Maven jar plugin. The entry contains the value ${installRoot} but
>> since there is no property associated with this, Maven converts it to
>> "null". In other words, is there a way that I can escape the
>> expression ${..}?
>>
>>
>> Thanks in advance!
>> Jane
>>
>> ---------------------------------------------------------------------
>> 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: escape ${some-value}

Posted by "David C. Hicks" <dh...@i-hicks.org>.
This may be of relevance, too...
http://maven.apache.org/plugins/maven-resources-plugin/examples/escape-filtering.html

David C. Hicks wrote:
> Hi Jane,
>
> I just happened to be looking for other information about "escaping"
> when I saw your question. Looks like you can use:
>
>     \${foobar}
>
> To cause the literal to be used. Here's a link to the page where I found
> this: http://maven.apache.org/shared/maven-filtering/
> Dave
>
>
> Jane Young wrote:
>   
>> Hi Maven Gurus,
>>
>> Is there a way to treat the literal value of ${foobar} instead of a
>> property?
>> For example I want to be able to put an entry in the manifest using
>> the Maven jar plugin. The entry contains the value ${installRoot} but
>> since there is no property associated with this, Maven converts it to
>> "null". In other words, is there a way that I can escape the
>> expression ${..}?
>>
>>
>> Thanks in advance!
>> Jane
>>
>> ---------------------------------------------------------------------
>> 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
>
>   

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


Re: escape ${some-value}

Posted by "David C. Hicks" <dh...@i-hicks.org>.
Hi Jane,

I just happened to be looking for other information about "escaping"
when I saw your question. Looks like you can use:

    \${foobar}

To cause the literal to be used. Here's a link to the page where I found
this: http://maven.apache.org/shared/maven-filtering/
Dave


Jane Young wrote:
> Hi Maven Gurus,
>
> Is there a way to treat the literal value of ${foobar} instead of a
> property?
> For example I want to be able to put an entry in the manifest using
> the Maven jar plugin. The entry contains the value ${installRoot} but
> since there is no property associated with this, Maven converts it to
> "null". In other words, is there a way that I can escape the
> expression ${..}?
>
>
> Thanks in advance!
> Jane
>
> ---------------------------------------------------------------------
> 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