当前位置: 首页 > 知识库问答 >
问题:

智能理念 - Maven2 - 安装

范承志
2023-03-14

我从私有存储库下载了一个项目,当我尝试安装时,我显示我需要Maven2的错误。问题是,当我下载IntelliJ IDEA时,我下载的是提供Maven3的最后一个版本。

问题是...有可能在IntelliJ IDEA中更改版本Maven吗?

因为另一个问题是当我安装项目时在控制台中显示下一个错误。

Downloading: http://repo1.maven.org/maven2/org/apache/maven/plugins/maven-site-plugin/2.0-beta-7/maven-site-plugin-2.0-beta-7.jar
[WARNING] Unable to get resource 'org.apache.maven.plugins:maven-site-plugin:maven-plugin:2.0-beta-7' from repository central (http://repo1.maven.org/maven2): Error transferring file: repo1.maven.org
[INFO] Skipping missing optional mojo: org.apache.maven.plugins:maven-site-plugin:attach-descriptor
Downloading: http://repo1.maven.org/maven2/org/apache/maven/plugins/maven-install-plugin/2.2/maven-install-plugin-2.2.jar
[WARNING] Unable to get resource 'org.apache.maven.plugins:maven-install-plugin:maven-plugin:2.2' from repository central (http://repo1.maven.org/maven2): Error transferring file: repo1.maven.org
[INFO] ------------------------------------------------------------------------
[ERROR] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] A required plugin was not found: Plugin could not be found - check that the goal name is correct: Unable to download the artifact from any repository

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-install-plugin -Dversion=2.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-install-plugin -Dversion=2.2 -Dpackaging=maven-plugin -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]


  org.apache.maven.plugins:maven-install-plugin:maven-plugin:2.2

from the specified remote repositories:
  central (http://repo1.maven.org/maven2)


  org.apache.maven.plugins:maven-install-plugin:maven-plugin:2.2

from the specified remote repositories:
  central (http://repo1.maven.org/maven2)

但我认为问题不在于代理,问题是 repo1.maven.org 是针对 maven3 的。

共有1个答案

谷梁嘉悦
2023-03-14

IntelliJ IDEA(Mac 上的版本 2019.1.3)设置路径以更改 Maven 主目录。

首选项|构建、执行、部署|构建工具|马文

 类似资料:
  • 我对硒比较陌生。目前,在我的公司,我们使用Eclipse创建并运行测试自动化(Maven/Cucumber/Selenium)。我们还将IntelliJIDEA用于Java开发 我的问题是,是否可以像使用Eclipse(Maven/Ccucumber/Selenium)一样使用IntelliJ IDEA进行自动化测试?我的意思是构建测试自动化脚本。如果是,那么您可以推荐任何解释如何为Intelli

  • 我如何让IDEA在Ubuntu中运行得更快?我正在一个具有6 gig RAM的i7 thinkpad中运行它。

  • 问题内容: 默认情况下,ubuntu带有openjdk。我从sun安装了jdk,并删除了openjdk,但是对于openjdk,我必须删除了maven2。如何在不安装openjdk的情况下重新安装它? 任何帮助表示赞赏,我已经在Google上搜索了很多,但没有找到任何解决方案:/ 问题答案: 您可以简单地从Maven 网站下载tar.gz归档文件,并将其解压缩到这样的某个目录(将其解压缩到/ op

  • PS:我尝试过从零开始导入项目,并多次进行无效和重新启动,但这没有帮助。

  • 项目设置正在生成中。gradle文件包含main、integratest、test和performancetest模块,每个模块都位于一组java类和资源文件夹中。 将项目导入Intellij时,单元测试无法正常工作,因为Intellij会将所有资源合并到一个文件夹中,直到在Intellij项目设置中选择- 有没有办法在构建中包含此配置。格雷德尔档案= 但是在设置这个之后,我所有的模块共享资源,这

  • 主要内容:什么是代理?,智能代理,理性代理:,AI代理的结构,PEAS代表AI系统可以定义为理性代理及其环境的研究。代理通过传感器感知环境并通过执行器对其环境起作用。AI代理可以具有知识,信仰,意图等心理属性。 什么是代理? 代理可以是通过传感器感知环境并通过执行器对该环境起作用的任何事物。代理在感知,思考和行动的循环中运行。代理可以是: 人体代理:人类代理人的眼睛,耳朵和其他器官,用于传感器和手,腿,致动器的声道工作。 机器人代理:机器人代理可以是摄像头,红外测距仪,

  • 开启智能助理 轻应用管理员进入企业管理后台,在应用功能/智能助理下开启智能助理功能。 订阅事件 事件订阅可以让轻应用收到轻推的事件通知。轻应用订阅事件后,若轻推触发了对应事件,开放平台会向轻应用配置的回调地址发送http请求以通知轻应用事件发生。 开启事件订阅步骤 步骤一:配置回调地址 登录轻推企业管理系统,依次点击轻应用/事件订阅,在请求网址URL中填写轻应用服务端接收回调请求的URL。保存回调