NetBeans is no longer generating a JAR file for code that it used to

本小妞迷上赌 提交于 2019-12-02 06:40:48

Well, I'm not sure why it was giving me that trouble, but I found a solution. The solution was to simply delete and then re-create the entire project from scratch, and then try compiling again. I'm guessing that NetBeans has updated the way they do manifest files or something like that with the different versions, and it was choking on the older version.

Had the same problem with Netbeans 7.1 and a project started with Netbeans 7.0.1.
When building the project, the the jar file was lacking some files, in my case the Main class. Recreating the project worked this out for me too. Thanks a lot!

Option 1: I tried to run the IDE with "Run as Administrator". It helped me to create the jar file properly

Option 2: a. After running "Clean and Build" Go to Netbeans Maven Project Navigator and right-click on the Execute Goal With Modifiers...

b. Remove "test-" from "org.apache.maven.plugins:maven-jar-plugin:2.3.2:test-jar" and selecting all the checkboxes as shown below (You may like to use the command later by selecting the "Remember as" checkbox)

I hope it will help someone

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!