开发者

Unable to run a Subclipsed Groovy script in Eclipse

After installing the Groovy plug-in in Eclipse, clicking Run brought up a list: Groovy Console - Groovy Script - Java Application. I'd select 开发者_开发问答Groovy Script and it would take off.

Now, after checking out a colleague's Groovy project with Subclipse, opening a script in it, clicking Run brings up "The selection cannot be launched, and there are no recent launches".

Selecting Run As... shows '(none applicable)'. So I select Run Configurations... and click Groovy Script, but the Run button stays dimmed. Eclipse evidently needs more info, but what?


I suspect your colleague didn't check in the .project file. It contains the "nature" that defines the project as being a Groovy project. I don't know for certain but it is not uncommon for eclipse actions to be predicated on the presence of an appropriate nature.

I would also check the .classpath is present and valid as it should contain the Groovy libraries required to compile and run your script.

Assuming they are missing, get your colleague to add them, and after syncing you should be good to go.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜