Currently, maven is used to compile the code. Changing a Java file will cause the entire project to be recompiled. (There is currently a lot of redundant code in the project, and it takes a long time to compile it all.)
Does the background compilation tool have an automatic compilation function similar to Eclipse? Only the changed code will be compiled each time?
黄舟2017-06-15 09:24:06
maven-compiler-plugin has a parameter useIncrementalCompilation that does not set the default fasle
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<version>${maven.compiler.version}</version>
<configuration>
<source>${java.version}</source>
<target>${java.version}</target>
</configuration>
<useIncrementalCompilation>true</useIncrementalCompilation>
</plugin>