Intellij IDEA – How to build project automatically

By default, Intellij IDEA doesn’t compile classes automatically. But, you can enable the auto compile feature by following steps :

  1. In “Project settings or preferences”
  2. Select “Build, Execution, Deployment -> Compiler”
  3. Checked Make project automatically
idea-build-project-automatically

P.S This feature is available since IDEA 12

References

  1. Brand New Compiler Mode in IntelliJ IDEA 12

mkyong

Founder of Mkyong.com, passionate Java and open-source technologies. If you enjoy my tutorials, consider making a donation to these charities.

4 Comments
Most Voted
Newest Oldest
Inline Feedbacks
View all comments
Urvi
6 years ago

Thank you, that was useful

Declan Whelan
6 years ago

Is there any way to make the setting turned on by default? I do this on every project and it would be nice to remove a manual step.

Stephan Rauh
8 years ago

Note that the project is only built if the application isn’t running. In my eyes, that makes it almost useless.

Taylor Stinson
8 years ago
Reply to  Stephan Rauh

Its meant for Unit testing mostly. Its very useful being able to type a few lines and check to see if a test goes green.

However what is annoying is that it doesn’t use a java-linter test before building wasting a lot of cycles.