Explore Courses Blog Tutorials Interview Questions
0 votes
in Java by (10.2k points)

I have a project that contains a single module, and some dependencies. I'd like to create a jar, in a separate directory, that contains the compiled module. In addition, I'd like to have the dependencies present beside my module.

No matter how I twist IntelliJ's "build jar" process, the output of my module appears empty (besides a META-INF file).

1 Answer

0 votes
by (46k points)

Check out this to learn how to build a jar with IntelliJ 10 

File -> Project Structure -> Project Settings -> Artifacts -> Click green plus sign -> Jar -> From modules with dependencies...

The foregoing sets the "structure" to where the jar will be stored. To create and save it do the following:

  1. Extract to the destination Jar

  2. OK

  3. Build -> Build Artifact

Browse Categories