title: Cannot create an executable .jar file with Netbeans 12.5
body: <p>After having created a Java application project in Netbeans 12.5, I click on Properties, then click on Run and set the main class. Eventually, I build the project. The problem is that when I try to run the .jar file with</p>
  <blockquote>
  <p>java -jar Example.jar</p>
  </blockquote>
  <p>I get the following message</p>
  <blockquote>
  <p>no main manifest attribute, in Example.jar</p>
  </blockquote>
  <p>Then I check the MANIFEST.MF file I don't find</p>
  <blockquote>
  <p>Main-Class: classname</p>
  </blockquote>
  <p>which is necessary to make the .jar executable.</p>
  <p>Do I have to add it manually? I thought that since I defined the main file in Properties-&gt;Run, the IDE would also write the main file in the MANIFEST.MF file automatically.</p>