java maven项目右键没有maven菜单问题

来源:互联网 发布:玄机科技工资 知乎 编辑:程序博客网 时间:2024/05/21 12:03

修改项目.project文件,确保有maven2Builder和maven2Nature2个标签

<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>projectName</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.eclipse.jdt.core.javabuilder</name>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>org.eclipse.m2e.core.maven2Builder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.jdt.core.javanature</nature>
<nature>org.eclipse.m2e.core.maven2Nature</nature>
</natures>
</projectDescription>
然后update Dependencies