(JAVA) Use Command Prompt to create .jar file from multiple .class files

后端 未结 4 1333
时光说笑
时光说笑 2021-01-11 23:00

I have written a .java file, called Main.java, and have compiled it using the javac in the Windows Command Prompt. The compiler is creating multiple .class files (called Mai

4条回答
  •  青春惊慌失措
    2021-01-11 23:26

    Something's gotta tell the java which class should be started automatically. That's the Manifest - see description here You have to package the Manifest.mf in your jar.

提交回复
热议问题