I have a project (Java Swing application), in which I want to mix Java and Groovy.
I can compile and run the project without problems inside IntelliJ Idea.
But I can't compile it with Maven:
src/main/groovy
I define a Groovy class GroovyClass
.src/main/java
there is a Java class, which uses GroovyClass
.[ERROR] ...\\JavaClass.java:[13,47] error: cannot find symbol
. How can I change the pom.xml
file in order to be able to compile and package the application using Maven?
Add the groovy-eclipse compiler maven plugin to your pom.xml
Instructions are on the plugins page at https://github.com/groovy/groovy-eclipse/wiki/Groovy-Eclipse-Maven-plugin
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.