How can I see the javac command IntelliJ IDEA uses to compile my code?

后端 未结 3 801
长发绾君心
长发绾君心 2021-01-05 06:54

When I write a Java code in IntelliJ IDEA and runs it, IntelliJ compiles the Java file, a class file is extracted and then the class file is run.

How can I see the

3条回答
  •  暗喜
    暗喜 (楼主)
    2021-01-05 07:44

    IDEA is not running java binary, so there is no way to see the commands. Instead, IDEA uses Java compiler API directly.

    If you want a raw representation of what is done to build the project, you can use Build | Generate Ant build. Examine the build file or run it from the command line via Ant to see what happens and what options/commands are invoked.

提交回复
热议问题