简体   繁体   English

在Eclipse中安装Maven插件(m2eclipse)的问题(Galileo)

[英]Problem installing Maven plugin (m2eclipse) in Eclipse (Galileo)

I have Eclipse Galileo (for Java EE Developers) installed, and I'm now trying to get the m2eclipse Maven plugin installed as well. 我安装了Eclipse Galileo(用于Java EE开发人员),我现在也尝试安装m2eclipse Maven插件。

I follow the basic steps described at http://m2eclipse.sonatype.org/installing-m2eclipse.html , and it seems to be installing just fine. 我按照http://m2eclipse.sonatype.org/installing-m2eclipse.html中描述的基本步骤进行操作,似乎安装得很好。 However, after restarting Eclipse after the install it doesn't seem to be anywhere. 但是,在安装后重新启动Eclipse后,它似乎不在任何地方。 I should for instance have the ability to create a new maven project, but when the new-project wizard opens, there is no folder for Maven (I also cannot find any reference to it in the context menus of the existing projects I have). 例如,我应该能够创建一个新的maven项目,但是当新项目向导打开时,Maven没有文件夹(我也无法在现有项目的上下文菜单中找到对它的任何引用)。

When I click at Help > About Eclipse > Installation Details, I find "Maven Integration for Eclipse (Required)" in the tab "Installed Software", yet another thing pointing towards a successful installation (but I can't find it under the "Plug-ins" tab, should it be there too?)... 当我单击帮助>关于Eclipse>安装详细信息时,我在“已安装的软件”选项卡中找到“Maven Integration for Eclipse(必需)”,另一个指向成功安装的东西(但我找不到它“插件“选项卡,是否也应该?”...

I feel like I'm just missing something very obvious, but right now I just don't see it... 我觉得我只是错过了一些非常明显的东西,但是现在我只是看不到它......

I managed to find the answer to this myself: 我自己找到了答案:

I had put the Eclipse installation folder under c:\\Program Files\\, but when I moved it directly under c:\\ instead, the plug-in installation worked just as it should. 我把Eclipse安装文件夹放在c:\\ Program Files \\下,但是当我直接在c:\\下移动时,插件安装就像它应该的那样工作。 I assume that is because Eclipse wasn't allowed to write to its own installation folder (but I didn't get the usual question from Windows that something was trying to access Program Files either...). 我认为这是因为Eclipse不允许写入自己的安装文件夹(但是我没有从Windows获得通常的问题,即某些东西试图访问程序文件......)。

In one way I feel like I should be a bit ashamed that I didn't think of this before. 在某种程度上,我觉得我应该感到有点惭愧,以前我没有想到这一点。 On the other hand though, there could have been some reasonable error message stating that something failed during the plug-in installation... 另一方面,可能有一些合理的错误消息表明在插件安装过程中出现了故障......

Well, I hope this at least helps somebody else as well :) 好吧,我希望这至少可以帮助别人:)

Did you check the m2eclipse installation requirements ? 你检查了m2eclipse的安装要求吗?
In particular, you need WTP. 特别是,您需要WTP。

"Maven integration for Eclipse" (core feature) and optional "Maven POM Editor" feature depend on the "Eclipse XML Editors and Tools" feature from WST “Maven Integration for Eclipse”(核心功能)和可选的“Maven POM编辑器”功能取决于WST的“Eclipse XML编辑器和工具”功能
"Maven integration for WTP" feature provides Maven project configuration for WTP “用于WTP的Maven集成”功能为WTP提供了Maven项目配置

问题已解决我有同样的问题,我使用以下软件站点:[“M2Eclipse - http://download.eclipse.org/technology/m2e/releases/1.0](没有方括号)下载Eclipse 3.7中的M2Eclipse插件.0(Indigo)。有关更多信息,请参阅此内容

To solve the problem of 'not getting Maven plugin running in eclipse' , it can be solved by altering admin rights to the .m2 folder . 要解决“不能在eclipse中运行Maven插件”的问题,可以通过更改.m2文件夹的管理员权限来解决。 Right click on .m2 folder and go to network sharing. 右键单击.m2文件夹,然后转到网络共享。 give all rights to all users. 给予所有用户所有权利。 Restart eclipse and maven options will start to appear in Eclipse. 重启eclipse和maven选项将开始出现在Eclipse中。

Did you have a previous version of m2eclipse installed? 您是否安装了m2eclipse的先前版本? Did you uninstall it before to install the latest version? 在安装最新版本之前,您是否卸载了它? Just in case, does the following note applies to you? 以防万一,以下说明是否适用于您?

Note about 0.9.8 Workspace Incompatibility: If you are using m2eclipse 0.10.0 with a workspace that contains projects created under m2eclipse 0.9.8, you must remove the workspaceState.ser file. 关于0.9.8工作区不兼容的注意事项:如果您使用m2eclipse 0.10.0,其工作空间包含在m2eclipse 0.9.8下创建的项目,则必须删除workspaceState.ser文件。 The workspaceState.ser file is located within the workspace directory in $workspacedir/.metadata/.plugins/org.maven.ide.eclipse/workspaceState.ser. workspaceState.ser文件位于$ workspacedir / .metadata / .plugins / org.maven.ide.eclipse / workspaceState.ser中的工作空间目录中。 If you remove this file, m2eclipse 0.10.0 will regenerate it as needed. 如果删除此文件,m2eclipse 0.10.0将根据需要重新生成它。

In my case, uninstalling the previous m2eclipse version didn't work and I had to start with a fresh Eclipse install (maybe try this also). 在我的情况下,卸载以前的m2eclipse版本不起作用,我不得不从一个全新的Eclipse安装开始(也许也尝试这个)。

Regarding the plugin tab, this is what I have (to confirm that you should definitely find something): 关于插件选项卡,这就是我所拥有的(确认你肯定应该找到的东西):

alt text http://www.imagebanana.com/img/84h6mw8z/screenshot_008.png alt text http://www.imagebanana.com/img/84h6mw8z/screenshot_008.png

Note that I also installed some extras from m2eclipse Extras Update Site: http://m2eclipse.sonatype.org/sites/m2e-extras 请注意,我还从m2eclipse Extras更新站点安装了一些额外内容: http//m2eclipse.sonatype.org/sites/m2e-extras

I was able to solve this problem by going into Program Files, right click on the eclipse.exe file and select "Run as administrator". 我可以通过进入Program Files来解决这个问题,右键单击eclipse.exe文件并选择“以管理员身份运行”。 When I restarted Eclipse it said I had no plugins installs so I reinstalled and my problems were solved. 当我重新启动Eclipse时,它说我没有插件安装,所以我重新安装,我的问题解决了。

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

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