Is it possible to generate a JAR, not WAR file?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Is it possible to generate a JAR, not WAR file?

edilista

Hi,

I have a situation where WAR is not good, because the file is very big and
in the major times I need to update only the JAR file. But I don't know very
much ANT and I didn't find where to change it to do this.

Thanks for any help,
Reply | Threaded
Open this post in threaded view
|

Re: Is it possible to generate a JAR, not WAR file?

wqtnetbeans
I don't know if you can do this with an NB webapp project. But is it
possible for you to set up an NB j2se project using the same "src" of
the web project? (The two project can not physically share the same
src dir on the hard disk by NB design. But you can make a copy of the
same src somewhere else.) That way you'll get a jar file all right....

Cheers,
Qingtian



On 7/26/05, edilista <[hidden email]> wrote:
>
> Hi,
>
> I have a situation where WAR is not good, because the file is very big and
> in the major times I need to update only the JAR file. But I don't know very
> much ANT and I didn't find where to change it to do this.
>
> Thanks for any help,
>
Reply | Threaded
Open this post in threaded view
|

RE: Is it possible to generate a JAR, not WAR file?

Richard Bremner-3
In reply to this post by edilista
Just put this into your build.xml file.

    <target name="-post-compile">
        <jar jarfile="JAR_FILE_NAME.jar" compress="true">
            <fileset dir="${build.classes.dir}">
                <exclude name="**/*.java"/>
            </fileset>
        </jar>
    </target>

I'm sure there are lots of better ways but it does it for me, because I need
both a war and jar.

Richard



-----Original Message-----
From: edilista [mailto:[hidden email]]
Sent: 26 July 2005 20:23
To: [hidden email]
Subject: [nbusers] Is it possible to generate a JAR, not WAR file?


Hi,

I have a situation where WAR is not good, because the file is very big and
in the major times I need to update only the JAR file. But I don't know very

much ANT and I didn't find where to change it to do this.

Thanks for any help,