Reputation: 224
I Have been having this issue for a while and today finally solved it.
When creating a Jar artifact in IntelliJ and trying to run it, I always got the error
no main manifest attribute, in xxxx.jar
Upvotes: 0
Views: 1258
Reputation: 224
The problem ONLY occured when I added library files to the artifact, and without external libraries the jar executed fine.
The process I followed to create the artifact was as follows :
File -> Project Structure -> Artifacts -> add Jar -> from modules with dependencies... -> After The Next Windows the following was shown
And my problem was fixed when I removed all the items that had 'Extracted" prefixes. I also added The Library File to look like this -> Which made my jar with library dependencies work again]2
Upvotes: 0