You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by Nathan Coast <na...@codeczar.com> on 2003/10/01 06:01:24 UTC

I'm confused - plugin installation dirs

AFAICT there are 3 directories that plugins can end up in

<maven_local_home>\repository\groupId\plugins

<maven_local_home>\repository\maven\plugins

<maven_home>\plugins

they are then extracted to

<maven_local_home>\plugins

executing plugin:install results in this output:

jar:jar:
     [copy] Copying 1 file to D:\apache\maven\local\repository\maven\plugins
plugin:install:
     [copy] Copying 1 file to D:\apache\maven\plugins

so the plugin gets copied to two dirs!

can someone explain which plugins should go where with the new 
plugins-as-artifacts model?  I'm having difficulty understanding what 
happens when a plugin is defined as a dependency.  If the plugin exists 
in multiple places which one takes precedence and why?

just spent a couple of hours trying to work out why old versions of 
plugins were being executed after I'd run plugin:install with newer 
versions.

thanks
Nathan


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


Re: I'm confused - plugin installation dirs

Posted by di...@multitask.com.au.
Nathan Coast <na...@codeczar.com> wrote on 01/10/2003 02:28:39 PM:

> not sure where that is coming from as the groupId in my project.xml is 
> ejbgen,
> 
> my plugin is still being copied to
> <maven_local_home>\repository\maven\plugins
> and
> <maven_home>\plugins
> 
Could be a bug in the plugin plugin?
--
dIon Gillard, Multitask Consulting
Blog:      http://blogs.codehaus.org/people/dion/



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


Re: I'm confused - plugin installation dirs

Posted by Nathan Coast <na...@codeczar.com>.
not sure where that is coming from as the groupId in my project.xml is 
ejbgen,

my plugin is still being copied to
<maven_local_home>\repository\maven\plugins
and
<maven_home>\plugins

dion@multitask.com.au wrote:

> Nathan Coast <na...@codeczar.com> wrote on 01/10/2003 02:01:24 PM:
> 
> 
>>AFAICT there are 3 directories that plugins can end up in
>>
>><maven_local_home>\repository\groupId\plugins
>>
>><maven_local_home>\repository\maven\plugins
> 
> 
> The above one is where groupId=='maven'.
> 
> 
>><maven_home>\plugins
>>
>>they are then extracted to
>>
>><maven_local_home>\plugins
>>
>>executing plugin:install results in this output:
>>
>>jar:jar:
>>     [copy] Copying 1 file to 
> 
> D:\apache\maven\local\repository\maven\plugins
> 
>>plugin:install:
>>     [copy] Copying 1 file to D:\apache\maven\plugins
>>
>>so the plugin gets copied to two dirs!
> 
> 
> plugin:install installs it into the local repo, and then into the plugin 
> dir for maven on execution.
> 
> 
>>can someone explain which plugins should go where with the new 
>>plugins-as-artifacts model?  I'm having difficulty understanding what 
>>happens when a plugin is defined as a dependency.  If the plugin exists 
>>in multiple places which one takes precedence and why?
> 
> 
> Only plugins in $MAVEN_HOME/plugins are expanded on execution.
> 
> The plugins in the local repository are there like all other artifacts, 
> stored for any other usage that may be needed of them.
> 
> 
>>just spent a couple of hours trying to work out why old versions of 
>>plugins were being executed after I'd run plugin:install with newer 
> 
> 
> plugin:install does this:
> 
>     <delete verbose="false">
>       <fileset dir="${maven.home}/plugins">
>         <include name="${pom.artifactId}-*.jar" />
>         <exclude name="${maven.final.name}.jar" />
>       </fileset>
>     </delete>
> 
>     <delete includeEmptyDirs="true" verbose="false">
>       <fileset dir="${maven.plugin.unpacked.dir}">
>         <include name="*.cache"/>
>         <include name="**/.processed" />
>         <include name="${pom.artifactId}-*/**" />
>         <exclude name="${maven.final.name}.jar" />
>       </fileset>
>     </delete>
> 
> that *should* remove old versions of the plugin. Are you sure you're using 
> plugin:install?
> 
> Can you provide a test case that doesn't fit the above deletes?
> --
> dIon Gillard, Multitask Consulting
> Blog:      http://blogs.codehaus.org/people/dion/
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
> 
> 
> 
> 


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


Re: I'm confused - plugin installation dirs

Posted by di...@multitask.com.au.
Nathan Coast <na...@codeczar.com> wrote on 01/10/2003 02:01:24 PM:

> AFAICT there are 3 directories that plugins can end up in
> 
> <maven_local_home>\repository\groupId\plugins
> 
> <maven_local_home>\repository\maven\plugins

The above one is where groupId=='maven'.

> <maven_home>\plugins
> 
> they are then extracted to
> 
> <maven_local_home>\plugins
> 
> executing plugin:install results in this output:
> 
> jar:jar:
>      [copy] Copying 1 file to 
D:\apache\maven\local\repository\maven\plugins
> plugin:install:
>      [copy] Copying 1 file to D:\apache\maven\plugins
> 
> so the plugin gets copied to two dirs!

plugin:install installs it into the local repo, and then into the plugin 
dir for maven on execution.

> can someone explain which plugins should go where with the new 
> plugins-as-artifacts model?  I'm having difficulty understanding what 
> happens when a plugin is defined as a dependency.  If the plugin exists 
> in multiple places which one takes precedence and why?

Only plugins in $MAVEN_HOME/plugins are expanded on execution.

The plugins in the local repository are there like all other artifacts, 
stored for any other usage that may be needed of them.

> just spent a couple of hours trying to work out why old versions of 
> plugins were being executed after I'd run plugin:install with newer 

plugin:install does this:

    <delete verbose="false">
      <fileset dir="${maven.home}/plugins">
        <include name="${pom.artifactId}-*.jar" />
        <exclude name="${maven.final.name}.jar" />
      </fileset>
    </delete>

    <delete includeEmptyDirs="true" verbose="false">
      <fileset dir="${maven.plugin.unpacked.dir}">
        <include name="*.cache"/>
        <include name="**/.processed" />
        <include name="${pom.artifactId}-*/**" />
        <exclude name="${maven.final.name}.jar" />
      </fileset>
    </delete>

that *should* remove old versions of the plugin. Are you sure you're using 
plugin:install?

Can you provide a test case that doesn't fit the above deletes?
--
dIon Gillard, Multitask Consulting
Blog:      http://blogs.codehaus.org/people/dion/



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