spring-boot-maven-plugin引入出现爆红(已解决)

作者:adventure.Li 时间:2021-06-06 12:05:35 

一、问题描述

换了一台电脑,重新进行idea安装配置。然后打开原来的项目结果引入spring-boot-maven-plugin出现爆红,而且spring-boot-starter-parent也不能引入。

二、解决办法

1.检查环境配置,主要是settings.xml此文件配置情况是否正确,是否加入阿里云镜像。最好用idea工具打开检查一下是否规范,此次我的问题就出在settings.xml报错了(网上随意复制粘贴了一个)。settings.xml配置文件以及idea工具打开查看的方式如下所示。

spring-boot-maven-plugin引入出现爆红(已解决)


<?xml version="1.0" encoding="UTF-8"?>
<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 http://maven.apache.org/xsd/settings-1.0.0.xsd">
<!-- 配置本地仓库地址 -->
<!--<localRepository>E:\maven\repository</localRepository>-->

<!-- 配置下载Jar包的镜像仓库地址 -->
<mirrors>

<mirror>
 <id>alimaven</id>
 <name>aliyun maven</name>
 <url>http://maven.aliyun.com/nexus/content/groups/public/</url>
 <mirrorOf>central</mirrorOf>
</mirror>

<mirror>
 <id>uk</id>
 <name>Human Readable Name for this Mirror.</name>
 <url>http://uk.maven.org/maven2/</url>
<mirrorOf>central</mirrorOf>
</mirror>

<mirror>
 <id>nexus</id>
 <name>internal nexus repository</name>
 <url>http://repo.maven.apache.org/maven2</url>
 <mirrorOf>central</mirrorOf>
</mirror>
</mirrors>

<profiles>
<!-- 下载源代码和Javadoc -->
<profile>
<id>downloadSources</id>
<properties>
<downloadSources>true</downloadSources>
<downloadJavadocs>true</downloadJavadocs>
</properties>
</profile>
</profiles>

<!-- 激活在profiles的配置项 -->
<activeProfiles>
<activeProfile>downloadSources</activeProfile>
</activeProfiles>

</settings>

2.检查代码是否出错,加上具体版本号。

参考:https://blog.csdn.net/weixin_41988224/article/details/104388981

来源:https://blog.csdn.net/qq_44654974/article/details/114459162

标签:spring-boot-maven-plugin,爆红
0
投稿

猜你喜欢

  • 详述 DB2 分页查询及 Java 实现的示例

    2023-04-21 12:39:12
  • Android支付宝支付的示例代码

    2022-06-20 02:32:49
  • Java Swing编写一个简单的计算器软件

    2023-08-12 06:24:04
  • C#实现左截取和右截取字符串实例

    2022-06-06 08:29:39
  • springboot连接不上redis的三种解决办法

    2022-03-21 20:57:23
  • C#实现将DataTable内容输出到Excel表格的方法

    2023-05-01 15:20:38
  • Java算法比赛常用方法实例总结

    2023-11-28 07:15:26
  • Android如何在Gradle中更改APK文件名详解

    2021-06-02 12:59:31
  • Java虚拟机JVM性能优化(三):垃圾收集详解

    2021-10-16 10:38:49
  • Java实现批量下载选中文件功能

    2021-09-09 17:57:45
  • 用Java实现24点游戏

    2022-07-18 20:56:14
  • Java利用过滤器实现完善登录功能

    2021-07-20 15:07:05
  • [Alibaba-ARouter]浅谈简单好用的Android页面路由框架

    2023-06-28 06:37:22
  • ArrayList在for循环中使用remove方法移除元素方法介绍

    2022-11-20 03:50:18
  • 常见的排序算法,一篇就够了

    2022-06-16 06:56:34
  • C# 系统热键注册实现代码

    2021-10-07 00:12:14
  • 详解Java中的日期类

    2022-08-27 17:14:03
  • 详解Spring中的FactoryBean

    2022-06-08 05:29:55
  • Android PopUpWindow使用详解

    2023-06-30 06:33:11
  • Maven管理SpringBoot Profile详解

    2022-03-20 09:57:45
  • asp之家 软件编程 m.aspxhome.com