简体   繁体   English

使用Gradle或Maven时Eclipse构建错误?

[英]Eclipse build errors when using Gradle or Maven?

When using a build manager like Gradle or Maven, my dependencies are being managed correctly, however the Eclipse IDE is unaware of the resolved dependencies so it will still show errors and I cannot build through Eclipse, I have to run a 'build' command through the build manager. 当使用诸如Gradle或Maven之类的构建管理器时,我的依赖关系得到了正确的管理,但是Eclipse IDE并未意识到已解决的依赖关系,因此它仍然会显示错误,并且我无法通过Eclipse进行构建,我必须通过以下命令运行“ build”命令生成经理。

How do you get Eclipse to be aware of the resolved dependencies taken care of by a build manager and running the app through the IDE? 您如何让Eclipse知道由构建管理器处理并通过IDE运行应用程序的已解决依赖关系?

You can generate Eclipse metadata using eclipse plugin distribute with Gradle - http://www.gradle.org/docs/current/userguide/eclipse_plugin.html - this will set up the project with its classpath. 您可以使用通过Gradle分发的eclipse插件生成Eclipse元数据-http: //www.gradle.org/docs/current/userguide/eclipse_plugin.html-这将使用其类路径来设置项目。

Or install Gradle plugin for Eclipse developed by Pivotal folks. 或安装由Pivotal员工开发的Gradle Eclipse插件。

The question is vague. 问题很模糊。 Using m2e or Gradle plugin for Eclipse developed by Pivotal can lead you to different errors. 使用Pivotal为Eclipse开发的m2e或Gradle插件会导致您遇到不同的错误。 You should ask exact question, sharing error that you got here on stackoverflow. 您应该提出确切的问题,共享在stackoverflow上遇到的错误。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM