You can create an "executable" jar by adding the following plugin configuration:
<plugin>
<artifactId>maven-jar-plugin</artifactId>
<configuration>
<archive>
<manifest>
<mainClass>your.main.clas</mainClass>
<addClasspath>true</addClasspath>
<classpathPrefix>lib/</classpathPrefix>
</manifest>
</archive>
</configuration>
</plugin>
On 4/27/06, Stefan Arentz <[EMAIL PROTECTED]> wrote:
> On 4/27/06, Wayne Fay <[EMAIL PROTECTED]> wrote:
> >
> > Maven is a project builder, not a project runner. There is no Maven
> > shortcut to run your main(). I have seen some people talk about
> > POMstrap so Google that and maybe you'll find something.
>
>
> Ok. Is there a way to package a jar then, that I can execute with java -jar?
>
>
> > As for your test problem, I have no idea what you're doing in your
> > configuration, this works properly out of the box. I assume you've
> > broken something in your pom.xml, or you're doing something
> > wacky/tricky in your tests.
>
>
>
> I was doing something stupid of course. And it does work out of the box.
>
> Thanks,
>
> S.
>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]