Spring和Maven插件安装问题; MVN;春天

发布于 2024-12-25 23:55:35 字数 1444 浏览 4 评论 0 原文

我有一个基于 Maven 的项目,我正在尝试将其导入到 Spring 源工具套件中。我收到以下错误。

Description Resource    Path    Location    Type
Could not calculate build plan: Missing:
----------
1) org.apache.maven.plugins:maven-resources-plugin:maven-plugin:2.4.2

  Try downloading the file manually from the project website.

  Then, install it using the command: 
      mvn install:install-file -DgroupId=org.apache.maven.plugins -DartifactId=maven-resources-plugin -Dversion=2.4.2 -Dpackaging=maven-plugin -Dfile=/path/to/file

  Alternatively, if you host your own repository you can deploy the file there: 
      mvn deploy:deploy-file -DgroupId=org.apache.maven.plugins -DartifactId=maven-resources-plugin -Dversion=2.4.2 -Dpackaging=maven-plugin -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]

----------
1 required artifact is missing.

for artifact: 
  org.apache.maven.plugins:maven-resources-plugin:maven-plugin:2.4.2

from the specified remote repositories:
  central (http://repo1.maven.org/maven2, releases=true, snapshots=false)
    Gamex       Unknown Maven Problem

看起来它要求我安装 Maven 资源插件 2.4.2,但我不确定要下载的文件是什么。我尝试下载 maven-plugin-plugin-2.4.2-source.jar 并将其提供给命令;但没有成功。 然后我去了 http: //svn.apache.org/viewvc/maven/plugins/tags/maven-resources-plugin-2.4.2/并下载pof.xml;这也行不通。 如果您之前遇到过这个问题,请帮助我了解缺少什么/或者错误消息是什么。

谢谢,

i've a maven based project and i'm trying to import it to Spring source tool suite. I am getting the following error.

Description Resource    Path    Location    Type
Could not calculate build plan: Missing:
----------
1) org.apache.maven.plugins:maven-resources-plugin:maven-plugin:2.4.2

  Try downloading the file manually from the project website.

  Then, install it using the command: 
      mvn install:install-file -DgroupId=org.apache.maven.plugins -DartifactId=maven-resources-plugin -Dversion=2.4.2 -Dpackaging=maven-plugin -Dfile=/path/to/file

  Alternatively, if you host your own repository you can deploy the file there: 
      mvn deploy:deploy-file -DgroupId=org.apache.maven.plugins -DartifactId=maven-resources-plugin -Dversion=2.4.2 -Dpackaging=maven-plugin -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]

----------
1 required artifact is missing.

for artifact: 
  org.apache.maven.plugins:maven-resources-plugin:maven-plugin:2.4.2

from the specified remote repositories:
  central (http://repo1.maven.org/maven2, releases=true, snapshots=false)
    Gamex       Unknown Maven Problem

It looks like it's asking me to install the maven resourource plugin 2.4.2 but I'm not sure what is the file to download. I tried downloading maven-plugin-plugin-2.4.2-source.jar and feeding it to the command; but it didn't work.
I then went to the maven repository in http://svn.apache.org/viewvc/maven/plugins/tags/maven-resources-plugin-2.4.2/ and downloaded the pof.xml; this also is not working.
If you have seen this problem before pls help me understand what is missing / or what the error message is.

Thanks,

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

仅此而已 2025-01-01 23:55:35

http://mirrors.ibiblio.org/pub/mirrors/maven2/org/apache/maven/plugins/maven-resources-plugin/2.4.2/ 并执行

      mvn install:install-file -DgroupId=org.apache.maven.plugins -DartifactId=maven-resources-plugin -Dversion=2.4.2 -Dpackaging=maven-plugin -Dfile=/path/to/file

清理操作eclipse:eclipse,清理Eclipse中的项目并刷新并尝试。它应该有效。

Download the maven resourource plugin 2.4.2[maven-resources-plugin-2.4.2.jar] from http://mirrors.ibiblio.org/pub/mirrors/maven2/org/apache/maven/plugins/maven-resources-plugin/2.4.2/ and do an

      mvn install:install-file -DgroupId=org.apache.maven.plugins -DartifactId=maven-resources-plugin -Dversion=2.4.2 -Dpackaging=maven-plugin -Dfile=/path/to/file

followed by clean eclipse :eclipse , clean the project in Eclipse and refresh and try . It should work .

风铃鹿 2025-01-01 23:55:35

您可能位于防火墙后面。您可以尝试设置 HTTP 代理来绕过防火墙。

在 Windows 中,此文件位于:C:\Documents and Settings\\.m2\settings.xml

您需要向 提供有效参数。 基于您的组织中网络的设置方式。

<settings 
...
     <proxies>

    <proxy>
      <active>true</active>
      <protocol>http</protocol>
      <host>put-ur-proxy-servername</host>
      <port>80</port>
    </proxy>
...
</settings>

You may be behind firewall. You could try to set an HTTP proxy to bypass the firewall.

In Windows, this file is located at: C:\Documents and Settings\<windows Login>\.m2\settings.xml

You need to provide valid parameters to the <proxy> based on how the network is setup in your organization.

<settings 
...
     <proxies>

    <proxy>
      <active>true</active>
      <protocol>http</protocol>
      <host>put-ur-proxy-servername</host>
      <port>80</port>
    </proxy>
...
</settings>
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文