Can I see the exact commands IntelliJ uses to build a java project?

Can I see the exact commands IntelliJ uses to build a java project?


Solution 1:

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.

Solution 2:

Look in ~/Library/Logs/IdeaIC13/build-log. You can turn on ALL debugging in build-log.xml in this directory. When you build inside IDEA, it writes a log to build.log in this directory.

Solution 3:

If you run a certain run configuration, check the output console (Ctrl+0) For example, it shows something like:

"C:\Program Files\Java\jdk1.5.0_22\bin\java" -Didea.launcher.port=7532 "-Didea.launcher...

Process finished with exit code 0

The first line is the command for building and running the module...