- mongodb - 在 MongoDB mapreduce 中,如何展平值对象?
- javascript - 对象传播与 Object.assign
- html - 输入类型 ="submit"Vs 按钮标签它们可以互换吗?
- sql - 使用 MongoDB 而不是 MS SQL Server 的优缺点
我完全是 Maven 的新手。我想用原型(prototype)为“webapp”的 Eclipse Juno EE 创建一个 Maven 项目。我安装了“Maven Integration for Eclipse WTP(孵化)”,我还安装了“Maven Integration for Eclipse”(在 Eclipse Marketplace 的已安装选项卡上找到它)。当我尝试从 File->New_>Maven Project 创建新项目时,出现错误:
Could not resolve archetype org.apache.maven.archetypes:maven-archetype-webapp:RELEASE from any of the configured repositories.Could not resolve artifact org.apache.maven.archetypes:maven-archetype-webapp:pom:RELEASEFailed to resolve version for org.apache.maven.archetypes:maven-archetype-webapp:pom:RELEASE: Could not find metadata org.apache.maven.archetypes:maven-archetype-webapp/maven-metadata.xml in local (C:\Documents and Settings\PEP35KD\.m2\repository)Failed to resolve version for org.apache.maven.archetypes:maven-archetype-webapp:pom:RELEASE: Could not find metadata org.apache.maven.archetypes:maven-archetype-webapp/maven-metadata.xml in local (C:\Documents and Settings\PEP35KD\.m2\repository)
It happens for all kinds of archetype.I am using a proxy, and I create file settings.xml under C:\Documents and Settings\PEP35KD.m2\ with this content:
<proxies>
<proxy>
<id>myId</id>
<active>true</active>
<protocol>http</protocol>
<username>rete\pep35kd</username>
<password>XXXX</password>
<host>XXXX</host>
<port>8080</port>
<nonProxyHosts>localhost</nonProxyHosts>
</proxy>
</proxies>
请考虑一下,我似乎无法从命令行使用 mvn 命令(找不到命令)。我从来没有安装过 Maven,我认为这个插件就足够了:这是一个正确的假设吗?
UPDATE 问题肯定与代理有关。作者:
一切都按预期进行。我真的不明白为什么,但可能是防火墙阻止了 Maven 服务器的流量。
最佳答案
我按照 this other StackOverflow question 的解决方案解决了这个问题。
I had the same problem. I fixed it by adding the maven archetype catalog to eclipse. Steps are provided below: (Please note the https protocol)
- Open Window > Preferences
- Open Maven > Archetypes
- Click 'Add Remote Catalog' and add the following:
- Catalog File: https://repo1.maven.org/maven2/archetype-catalog.xml
- Description: maven catalog
关于java - 在Eclipse中创建一个Maven项目提示 "Could not resolve archetype",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/15506043/
我正在尝试使用以下命令创建一个简单的 Maven 3.0.3 项目: mvn -X archetype:generate -DarchetypeArtifactId=maven-archetype-
我正在尝试学习一些 Maven,尤其是如何创建自己的原型(prototype)。然后我遇到了 Maven 提供的默认的。原型(prototype)“org.apache.maven.archetype
运行命令 mvn archetype:generate > a.txt 的输出片段: 332: remote -> org.apache.maven.archetypes:maven-archetyp
首先,我创建了一个原型(prototype)项目并将其安装到本地 maven 存储库。 接下来,我跑了mvn archetype:crawl生成 archetype-catalog.xml在 C:\U
当我尝试创建一个简单的 Maven 项目时收到上述错误消息。我已经用尽了以前的建议,例如Window > Preferences > Maven > Archetypes > Add Remote C
快速启动原型(prototype)似乎不起作用。mvn archetype:生成-DgroupId = com.mycompany.app -DartifactId = my-app -Darchet
我安装了maven 3.3.3,安装成功。 但是,在尝试在 Eclipse 中创建 Maven 项目时出现以下错误 'Creating maven-archtype-quickstart' has e
与 Dexterity内容类型,规范的方法是使用转换器: from plone.app.textfield.interfaces import ITransformer from plone.app.
是否有可能或工作方法使用 maven-archetype-webapp 原型(prototype)来生成具有简单目录结构的 maven webapp,例如 /src /main
我正在尝试卸载collective.carousel的原型(prototype)schemaextender(我只对该包中的portlet感兴趣,而不是将Carousel源添加到每个PloneForm
这个问题在这里已经有了答案: Failed to resolve version for org.apache.maven.archetypes (19 个回答) 关闭6年前。 我完全是 Maven
Archetype 是 Maven 项目的模板工具包,它定义了 Maven 项目的基本架构。Archetype 为开发人员提供了数千种创建 Maven 项目的模板,Maven 通过这些模板可以帮助用户
我创建了一个 Maven 原型(prototype)。我的 META-INF/maven/archetype-metadata.xml 看起来像这样: src/main/
我使用 Maven 创建了一个原型(prototype),它创建了一个项目。为了测试项目,我通常必须生成项目并运行 mvn clean install 以确保它成功构建。 我正在寻找一种方法来测试将从
我目前正在使用 Maven 3.3.3,其中 mvn.bat文件已被删除。推荐的也是唯一运行 Maven 的方法现在是通过 mvn.cmd文件。 我正在使用调用 maven-invoker 插件进行某
我使用了 vaadin-archetype-application-multimodule listed here并在 on this wiki page 上进行了讨论. 原型(prototype)生
假设我设置了 groupId至com.example , 和 artifactId至fancy.project ,现在我想创建一个原型(prototype),以便在创建时扩展为以下结构: |--src
我在其他地方找不到这个问题的答案。 我正在尝试设置一个虚拟机来学习 spring、wicket 和 hibernate。我从 this 开始maven-archetype 并像这样使用它: mvn a
我需要修复 archetypes.querywidget,它的构建没有创建 bin/test 脚本。 我应该使用 buildout.coredev 吗?我是否需要更改它的结帐以运行测试? 最佳答案 是
我在互联网上搜索了一段时间,但没有找到任何有用的东西...... 我想做一些简单的事情,例如在保存/创建 AT 内容类型后将页面重定向到列表页面(文件夹)。 我已经知道我必须使用 validate_i
我是一名优秀的程序员,十分优秀!