如何使用eclim与gradle项目 [英] How to use eclim with gradle project

查看:196
本文介绍了如何使用eclim与gradle项目的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的eclim设置与eclipse项目完美配合。但我想使用gradle构建系统。
我正在与Libgdx框架一起工作,它提供了gradle templete项目。
所以有什么办法使用eclime + eclipse + gradle

解决方案

最好的办法是查看<一个href =http://www.gradle.org/docs/current/userguide/eclipse_plugin.html =nofollow> Eclipse Gradle插件,虽然简而言之,您可以添加应用插件:'eclipse'到您的项目,然后从项目的根文件夹中的终端运行 gradle eclipse 。这应该为Eclipse生成必要的文件来识别您的项目,尽管您可能需要编辑 .classpath 文件进行正确的自动填充。



这将使Eclim通过以下方式识别您的项目:ProjectOpen和正确的自动完成和其他优点。



不好的是,Gradle任务和您的build.gradle的更改将需要手动更改Eclipse方面的事情。



编辑:有一个新的插件可用于替代eclim for gradle项目(但是面向Android)称为 Vim-Grand 。它是pre-alpha,你现在想要重构分支,但它对我来说工作得很好。


My eclim setup working perfectly with eclipse project. But I want to use gradle build system. I am working with Libgdx framework and it provide gradle templete project. So is there any way to use eclime + eclipse + gradle

解决方案

Your best bet is to check out the Eclipse Gradle plugin, although in short you can add apply plugin: 'eclipse' to your project and then run gradle eclipse from your terminal in the root folder of your project. That should generate the necessary files for Eclipse to recognize your project, although you might need to edit the .classpath file for proper autocompletions.

That will get Eclim to recognize your project with :ProjectOpen and proper autocompletion and other goodness.

The bad is that Gradle tasks and changes to your build.gradle will require manual changes to the Eclipse side of things.

Edit: There's a new plugin available for this purpose that replaces eclim for gradle projects (but is android oriented) called Vim-Grand. It's pre-alpha and you'll want the refactor branch for now, but it's working well enough for me

这篇关于如何使用eclim与gradle项目的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆