You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by Stephane Nicoll <st...@gmail.com> on 2007/11/02 07:31:10 UTC

Re: Not replacing token in plugin's parameters

Kenney, Daniel (and others)

I've seen another thread on resources filtering[1] where it is stated
that $${pom.version} would inject ${pom.version} (and not the value)
in a mojo field.

Hey cool, that answers my question. The only problem is that it does not work :)

If I do:

$${artifactId}.$${extension} I get my-war-project.${extension} (where
my-war-project is the artifactId of the current project).

If I replace artifactId with artifactId2 for instance it's not
replaced. It sounds like that using this $$ mechanism works if the
value is undefined.

I'd like to fix MWAR-116 for the next alpha so if any of you has more
info, please share.

Stéphane


[1] http://www.mail-archive.com/dev@maven.apache.org/msg68630.html

On 9/12/07, Stephane Nicoll <st...@gmail.com> wrote:
> Hi,
>
> In the trunk of the war plugin, the artifacts can be packaged in
> WEB-INF/lib with a custom name, a la assembly plugin. This leads to a
> config like this for instance:
>
> <outputFileNameMapping>
>   ${artifactId}.${extension}
> </outputFileNameMapping>
>
> This worked for a while and "suddently" (that's the weird thing) it
> stopped. The reason for that is maven "now" (?) resolves the tokens
> before injecting the value in the plugin (so for instance foo.null
> where foo is the artifactId of the current project instead of
> ${artifactId}.${extension}).
>
> Questions:
>
> - I can reproduce with Maven 2.0.5, 2.0.6 and 2.0.7 so it's something
> related to the plugin generation maybe?
> - I am wondering if I could add a tag on field-level to disable this
> automatic resolution
>
> Any advice, thoughts?
>
> Thanks,
> Stéphane
>
> [1] http://jira.codehaus.org/browse/MWAR-116
> --
> Large Systems Suck: This rule is 100% transitive. If you build one,
> you suck" -- S.Yegge
>


-- 
Large Systems Suck: This rule is 100% transitive. If you build one,
you suck" -- S.Yegge

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