java 使用 maven 时“未找到前缀应用引擎的插件”
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/25512591/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
"Plugin not found for prefix app engine" when using maven
提问by Tyler
I am trying to run the command
我正在尝试运行命令
mvn appengine:devserver
but it throws the following error
但它会引发以下错误
[ERROR] No plugin found for prefix 'appengine' in the current project and in the plugin groups
[org.apache.maven.plugins, org.codehaus.mojo] available from the repositories [local
(/Users/tylerrice/.m2/repository), central (https://repo.maven.apache.org/maven2)] -> [Help 1]
I have never used maven before all this code is from a development company we hired to write the majority of the backend so I am completely lost here. I visited the help page for this error here. I went through the list there and I can't find a pom.xml file either
在所有这些代码来自我们聘请来编写大部分后端的开发公司之前,我从未使用过 maven,所以我完全迷失在这里。我在这里访问了此错误的帮助页面。我浏览了那里的列表,但也找不到 pom.xml 文件
采纳答案by Jigar Joshi
in your build life cycle you don't have this plugin defined you can verify it by
在您的构建生命周期中,您没有定义此插件,您可以通过以下方式验证它
mvn help:effective-pom
and observe <build>
并观察 <build>
you need to let maven know what is this plugin and for that you need to add it to <build>
like
你需要让 maven 知道这个插件是什么,为此你需要添加它<build>
喜欢
<build>
<plugins>
<plugin>
<groupId>com.google.appengine</groupId>
<artifactId>appengine-maven-plugin</artifactId>
<version>1.9.9</version>
</plugin>
</plugins>
</build>
See More
查看更多
回答by Brad
So I had this same error. When I tried to run mvn appengine:devserver for appengine I was getting this same error
所以我有同样的错误。当我尝试为 appengine 运行 mvn appengine:devserver 时,我遇到了同样的错误
[ERROR] No plugin found for prefix 'appengine' in the current project and in the plugin groups [org.apache.maven.plugins, org.codehaus.mojo] available from the repositories [local (/Users/
I realized that I was up one directory too far, so when I was typing ls and hitting enter I could see my application. I simply needed to type cd [name of application] to go down one directory level to the application itself and it ran fine.
我意识到我上一个目录太远了,所以当我输入 ls 并按 Enter 时,我可以看到我的应用程序。我只需要键入 cd [应用程序名称] 以向下一级目录到应用程序本身,并且它运行良好。
回答by Shillz
In your POM file the appengine VERSION needs to be explicitly specified. (Not sure why).
在您的 POM 文件中,需要明确指定 appengine VERSION。(不知道为什么)。
" com.google.appengine appengine-maven-plugin 1.9.15 "
“ com.google.appengine appengine-maven-plugin 1.9.15 ”
回答by Eli
I had the same problem, nothing helped me, I worked around it by running the app server from the appengine home with the location to my app:
我遇到了同样的问题,没有任何帮助,我通过从 appengine 主页运行应用程序服务器来解决它,并将位置信息发送到我的应用程序:
C:\Downloads\appengine-java-sdk-1.9.24\appengine-java-sdk-1.9.24\bin>dev_appserver.cmd C:\projects\google_app_engine\guestbook_tutorial\guestbook\target\guestbook-1.0-SNAPSHOT\
C:\Downloads\appengine-java-sdk-1.9.24\appengine-java-sdk-1.9.24\bin>dev_appserver.cmd C:\projects\google_app_engine\guestbook_tutorial\guestbook\target\guestbook-1.0-SNAPSHOT\