You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Jeff Jensen <je...@upstairstechnology.com> on 2005/11/06 05:58:32 UTC

[m2] plugins vs dependencies

Hello,

If I understand plugins and dependencies correctly, JUnit is a plugin.  Yet,
the POM examples I see have it as a dependency.  It seems useful to have it
as a dependency, as then one can use <scope>test</scope>.

I don't know how one could specify a dependency as a plugin, but vice-versa
is true (and common?).

So then what is the difference in specifying a plugin as a dependency vs as
a plugin?
I'm trying to determine what to setup in plugins vs pluginManagement vs
dependencyManagement vs dependencies.

Is there any written guidance on this?  I searched Nabble for plugin vs
dependency, but was not successful; also didn't find clarification on the
docs page.


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


Re: [m2] plugins vs dependencies

Posted by dan tran <da...@gmail.com>.
Jeff,
 Invoking junit is part of maven-core, but the user have to declare junit
as dependency with test scope with their own version. ie junit is not a
plugin.
 you dont specify plugin as dependency but as plugin declaration in <build>
However, you can use pluginManagement at root pom to ensure all child
poms use the same plugin version.
 -Dan


 On 11/5/05, Jeff Jensen <je...@upstairstechnology.com> wrote:
>
> Hello,
>
> If I understand plugins and dependencies correctly, JUnit is a plugin.
> Yet,
> the POM examples I see have it as a dependency. It seems useful to have it
> as a dependency, as then one can use <scope>test</scope>.
>
> I don't know how one could specify a dependency as a plugin, but
> vice-versa
> is true (and common?).
>
> So then what is the difference in specifying a plugin as a dependency vs
> as
> a plugin?
> I'm trying to determine what to setup in plugins vs pluginManagement vs
> dependencyManagement vs dependencies.
>
> Is there any written guidance on this? I searched Nabble for plugin vs
> dependency, but was not successful; also didn't find clarification on the
> docs page.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>