0

I've created a Groovy project and build with Gradle from command line, all fine. But after load it into eclipse, I got lots of following errors inside the IDE. The project build path is pointing to these non-exist jars.

Project 'nexus' is missing required library: 'C:\Users\jironghu.gradle\caches\modules-2\files-2.1\commons-beanutils\commons-beanutils\1.8.0\c651d5103c649c12b20d53731643e5fffceb536\commons-beanutils-1.8.0.jar'

Jirong Hu
  • 2,315
  • 8
  • 40
  • 63
  • 1
    Not meant to be a troll comment but...my experience with using Groovy in Eclipse was bad. If you have a moment, I'd download IntelliJ IDEA for evaluation. Open your Groovy/Grails project in IDEA usually "just works". – Todd W Crone Jan 31 '16 at 16:12
  • Thanks for the suggestion, but not good experience for me. Can't even start the first step: http://stackoverflow.com/questions/22593733/intellij-idea-13-1-updating-maven-repository-index-authentication-failure. How can people release such a software? Everybody uses Maven central. – Jirong Hu Feb 01 '16 at 18:47
  • Gradle uses same repositories as Maven. That is not the issue. Eclipse is the issue. – Todd W Crone Feb 01 '16 at 19:53
  • I deleted these missing libraries from the Project Build Path. Now I am getting a red "x" in many import statements such as "import org.junit.After". The error is Groovy: Unable to resolve class org.junit.After". How can I let the eclipse project know the location of the external jar files referenced in build.gradle dependencies { compile 'junit:junit:4.11' } – Jirong Hu Feb 23 '16 at 22:18

1 Answers1

0

My bad, the eclipse project was generated in another company where my id was different. Just need to delete the eclipse .project and .classpath re-create them by "gradlew eclipse".

Jirong Hu
  • 2,315
  • 8
  • 40
  • 63