You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Anshuman Srivastava <an...@gmail.com> on 2006/04/26 06:26:16 UTC

Plugin for Maven

Hi,
I am using maven2.0.3 and fairly new to Maven.

Anyone please tell me that using Maven Plugin is same as adding the
information in dependency section of pom.xml like --

<dependency>
   <groupId>javax.servlet</groupId>
      <artifactId>servlet-api</artifactId>
   <version>2.3</version>
   <scope>provided</scope>
  </dependency>
.
If its not the same then what is the difference between plugins and these
dependencies?

Thanks
Anshuman

Re: Plugin for Maven

Posted by Tom Joad <tj...@gmail.com>.
Hi,
Maven can be viewed as a core and a concept  with enormeous plugins to
perform tasks.
To Use plugin you have to declare it under <plugins> <plugin> tags as
you do for dependencies. You must read plugin documentation to set
parameters value used by it to perform the task.
Please read
http://maven.apache.org/plugins/index.html
You put goal  Parameters under <configuration> tag of <plugin>
It is possible to bind plugin execution to a lifecycle phase
(compile,generate-sources ...)

Tom




2006/4/26, Anshuman Srivastava <an...@gmail.com>:
> Hi,
> I am using maven2.0.3 and fairly new to Maven.
>
> Anyone please tell me that using Maven Plugin is same as adding the
> information in dependency section of pom.xml like --
>
> <dependency>
>    <groupId>javax.servlet</groupId>
>       <artifactId>servlet-api</artifactId>
>    <version>2.3</version>
>    <scope>provided</scope>
>   </dependency>
> .
> If its not the same then what is the difference between plugins and these
> dependencies?
>
> Thanks
> Anshuman
>
>

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


Re: Plugin for Maven

Posted by James Mitchell <jm...@apache.org>.
Not exactly.  A plugin is a component that Maven recognizes and can  
use to perform some task.  When you declare a dependency (as below)  
you are simply telling Maven that your project needs that resource  
for the specified scope.

It would help if you went through a few tutorials and tried a few  
things with it.

This article is a little dated, and covers Maven 1, but I think it  
would help get you bootstrapped into a better understanding of what  
Maven is about:

  http://www.theserverside.com/articles/article.tss?l=MavenMagic

HTH


--
James Mitchell

P.S. -- Google is your friend



On Apr 26, 2006, at 12:26 AM, Anshuman Srivastava wrote:

> Hi,
> I am using maven2.0.3 and fairly new to Maven.
>
> Anyone please tell me that using Maven Plugin is same as adding the
> information in dependency section of pom.xml like --
>
> <dependency>
>    <groupId>javax.servlet</groupId>
>       <artifactId>servlet-api</artifactId>
>    <version>2.3</version>
>    <scope>provided</scope>
>   </dependency>
> .
> If its not the same then what is the difference between plugins and  
> these
> dependencies?
>
> Thanks
> Anshuman


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