To compile my Java/Lombok-project after adding a Groovy class, I added this configuration to my pom.xml, as instructed on Maven Groovy and Java + Lombok:
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.3</version>
<dependencies>
<dependency>
<groupId>org.codehaus.groovy</groupId>
<artifactId>groovy-eclipse-compiler</artifactId>
<version>2.9.2-01</version>
</dependency>
<dependency>
<groupId>org.codehaus.groovy</groupId>
<artifactId>groovy-eclipse-batch</artifactId>
<version>2.4.3-01</version>
</dependency>
</dependencies>
<configuration>
<compilerId>groovy-eclipse-compiler</compilerId>
<verbose>true</verbose>
<compilerArguments>
<javaAgentClass>lombok.launch.Agent</javaAgentClass>
</compilerArguments>
<fork>true</fork>
</configuration>
</plugin>
<plugin>
<groupId>org.codehaus.groovy</groupId>
<artifactId>groovy-eclipse-compiler</artifactId>
<version>2.9.2-01</version>
<extensions>true</extensions>
</plugin>
However, building then fails after this:
Fatal error compiling: Cannot find the requested className <lombok.launch.Agent> in classpath -> [Help 1]
When inspecting lombok-1.16.16.jar, it does contain a class called Agent inside the lombok/launch path, and the class path contains that jar file inside my .m2
Can someone tell me what I have to do to make my project build?