Thanks Kenney, it works. But, to make it useful, I need to put all the
jar files in one directory, because maven puts just the jar file names
in the classpath.
Right now I have them in .m2/repository, in their subdirectories. I
guess, I will create a directory with soft links for my run environment.
Is there a task in maven2 to automate this?

-----Original Message-----
From: Kenney Westerhof [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, April 19, 2005 10:29 AM
To: Maven Users List
Subject: Re: Maven2 jar classpath


On Tue, 19 Apr 2005, Ilyevsky, Leonid (Equity Trading) wrote:


use this:

    <build>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-jar-plugin</artifactId>
        <configuration>
          <archive>
            <manifest>
              <addClasspath>true</addClasspath>
            </manifest>
          </archive>
        </configuration>
      </plugin>
    </build>

But beware, only dependencies with <scope>runtime</scope> get included
in the classpath.

Greetings,

        Kenney Westerhof

> As my dependency list grows, I would like maven 2 to automatically
> generage class path in the manifest from dependency information.
> How should I specify it in pom.xml?
> --------------------------------------------------------
>
> If you are not an intended recipient of this e-mail, please notify the
sender, delete it and do not read, act upon, print, disclose, copy,
retain or redistribute it. Click here for important additional terms
relating to this e-mail.     http://www.ml.com/email_terms/
> --------------------------------------------------------
>

--
Kenney Westerhof
http://www.neonics.com
GPG public key: http://www.gods.nl/~forge/kenneyw.key

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


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

Reply via email to