Creating a batch file, for simple javac and java command execution

前端 未结 11 2582
终归单人心
终归单人心 2021-02-15 14:18

It is a really simple thing but I cannot get my head around it. I have looked at plenty of StackOverFlow post and as well as on internet.

My goal is to create a .bat whi

11条回答
  •  灰色年华
    2021-02-15 14:46

    I do not have a JDK installed on my machine to verify this, but here's something to get you started with

    %CLASSPATH%=C:\Program Files\Java\jdk1.6\bin rem or whatever your path is
    START %CLASSPATH%\javac Main.java
    START %CLASSPATH%\java Main
    

提交回复
热议问题