install is part of the build lifecycle...

mvn install will
* generate-resources
* process-resources
* generate-sources
* process-sources
* compile
* test-compile
* test
* package
* install into local repo

On Wednesday 26 September 2007 12:08, Jim Sellers wrote:
> mvn install will just compile the source.  I don't think that it will even
> compile the tests (you need mvn test-compile or something like that)
>
> If you want to "install" your artifact into your local repo, you need to
> run "mvn install".
>
> HTH
>
> Jim
>
> On 9/25/07, James Depaul <[EMAIL PROTECTED]> wrote:
> > Hi all -
> >
> > I'm a little confused about how maven resolves dependencies that I have
> > defined for my project modules.  I have the following project directory
> > structure:
> >
> >       cods (main dir )
> >             CodsCommon (sub-dir)
> >             CodsWeb (sub-dir)
> >
> > I have a pom.xml file setup in cods directory, which defines CodsCommon
> > and
> > CodsWeb as two modules (CodsCommon and CodsWeb each have individual
> > pom.xml
> > files, as well).
> >
> > The CodsWeb module has a dependency on CodsCommon - and requires that
> > CodsCommon be built first. Exerpt from pom.xml file in CodsWeb module
> > looks
> > like this:
> >             ...
> >             <dependency>
> >                   <groupId>maersk</groupId>
> >                   <artifactId>CodsCommon</artifactId>
> >                   <version>1.0-SNAPSHOT</version>
> >             </dependency>
> >
> > My question is:  when I run the 'mvn compile' command it all works
> > properly: the dependency to Common (shown below) gets resolved even
> > though the artifact does NOT seem to get installed in my .m2 local
> > repository?! It seems a little strange - I kind of expected my CodsCommon
> > artifact to be
> > installed after/during command execution..   So the mystery is: the
> > dependent module didn't get installed in .m2, but somehow this dependency
> > got resolved at run-time... hence my confusion.
> >
> > A little clarification please -
> >
> > Thanks,
> > James

-- 
Michael McCallum
Enterprise Engineer
mailto:[EMAIL PROTECTED]

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to