Making JAR file tutorial?


Is there a tutorial for making JAR with IntelliJ? In the last few days, I have tried and failed in making a working JAR file. I've installed a JAR tool plugin from the plugin repository, and was able to run that tool and make a JAR file, but I'm unable to run that JAR file.

ex. java -jar sampleprog.jar

Thanks in advanced.

1 comment
Comment actions Permalink

You will need to have a main-class attribute set in the manifest for the jar to be able to run it for you.
The built-in jar support can do that, maybe your plugin cannot (or you didn't notice the option).


Please sign in to leave a comment.