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

前端 未结 3 1347
暗喜
暗喜 2021-01-27 04:52

Two years ago I wrote a simple upload applet using Java, developed using NetBeans. When I first hit \"Clean and Build\" back then, and for some time afterwards, it worked perfec

相关标签:
3条回答
  • 2021-01-27 05:12

    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.

    0 讨论(0)
  • 2021-01-27 05:12

    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!

    0 讨论(0)
  • 2021-01-27 05:34

    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

    0 讨论(0)
提交回复
热议问题