java 在当前项目和存储库中可用的插件组 [] 中找不到前缀“war”的插件
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/40561536/
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
No plugin found for prefix 'war' in the current project and in the plugin groups [] available from the repositories
提问by yuva ツ
I'm trying resteasy webservice example.
我正在尝试 resteasy webservice 示例。
getting No plugin found for prefix 'war' in the current project and in the plugin groups [] available from the repositorieserror in the pom.xml file.
越来越没有在当前的项目和插件组[]可从存储库中找到的前缀“War”插件在pom.xml文件中的错误。
pom.xml
pom.xml
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.javacodegeeks.areyes</groupId>
<artifactId>resteasy-sample</artifactId>
<packaging>war</packaging>
<version>0.0.1-SNAPSHOT</version>
<name>resteasy-sample Maven Webapp</name>
<url>http://maven.apache.org</url>
<repositories>
<repository>
<id>JBoss repository</id>
<url>https://repository.jboss.org/nexus/content/groups/public-jboss/</url>
</repository>
</repositories>
<dependencies>
<dependency>
<groupId>org.jboss.resteasy</groupId>
<artifactId>resteasy-jaxrs</artifactId>
<version>2.2.1.GA</version>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>3.8.1</version>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<finalName>resteasy-sample</finalName>
</build>
already added M2_HOME and path in environment variable. how can i resolve it?
已经在环境变量中添加了 M2_HOME 和路径。我该如何解决?
回答by yuva ツ
You need to execute maven-war-plugin
你需要执行 maven-war-plugin