jar,怎样修改(或添加)它的“Manifest”,使之能够作为较独立的应用程序运行?
java文档这样说:
“Special-Purpose Manifest Headers”
Applications Bundled as JAR Files - version 1.2 only
If you have an application bundled in a JAR file, you need some way to indicate which class within the JAR file is your application's entry point. (Recall that the entry point is the class having a method with signature public static void main(String[] args).)
You provide this information with the Main-Class header, which has the general form:
Main-Class: classname
The value classname is the name of the class that is your application's entry point.
我怎样添加 "Main-Class: classname" 呢?