Failed to execute goal org.springframework.boot:spring-boot-maven-plugin:2.1.3.RELEASE:repac

简介: Failed to execute goal org.springframework.boot:spring-boot-maven-plugin:2.1.3.RELEASE:repac

[ERROR] Failed to execute goal org.springframework.boot:spring-boot-maven-plugin:2.1.3.RELEASE:repackage (repackage) on project learn-yaohao: Execution repackage of goal org.springframework.boot:spring-boot-maven-plugin:2.1.3.RELEASE:repackage failed: Unable to find a single main class from the following candidates [com.liupei.yaohao.Test, com.liupei.yaohao.YhUtils] -> [Help 1]

 

 

1.看看maven有没有配置。

2.pom.xml中加入这个刷新开发工具

 <build>
        <plugins>
            <!-- 生成主类 -->
            <plugin>
                <groupId>org.springframework.boot</groupId>
                <artifactId>spring-boot-maven-plugin</artifactId>
                <configuration>
                    <!--<mainClass>com.xjzd.ServerEurekaApplication</mainClass>-->
                    <includeSystemScope>true</includeSystemScope>
                </configuration>
            </plugin>
        </plugins>
    </build>

 

相关文章
|
Java Spring
【Spring常见错误】Initialization failed for ‘https://start.spring.io‘
📋📋 精彩摘要:新建SpringBoot项目时,使用官网连接创建项目报错: Initialization failed for 'https://start.spring.io' Please check URL, network and proxy settings. 本文将提供两种解决方式参考。
5885 0
【Spring常见错误】Initialization failed for ‘https://start.spring.io‘
|
8天前
|
Java Spring
Initialization failed for 'https://start.spring.io' Please check URL, network and proxy settings.
Initialization failed for 'https://start.spring.io' Please check URL, network and proxy settings.
371 0
|
7月前
|
Java Spring
Java报错Project ‘org.springframework.boot:spring-boot-starter-parent:2.x.0.RELEASE
Java报错Project ‘org.springframework.boot:spring-boot-starter-parent:2.x.0.RELEASE
|
druid Java
Failed to bind properties under 'spring.datasource' to javax.sql.DataSource:
Failed to bind properties under 'spring.datasource' to javax.sql.DataSource:
712 0
Failed to bind properties under 'spring.datasource' to javax.sql.DataSource:
|
11月前
|
缓存
Project ‘org.springframework.boot:spring-boot-starter-parent:1.5.7.RELEASE‘ not found
Project ‘org.springframework.boot:spring-boot-starter-parent:1.5.7.RELEASE‘ not found
|
缓存
project ‘org.springframework.boot:spring-boot-starter-parent:2.1.4.RELEASE‘ not found
project ‘org.springframework.boot:spring-boot-starter-parent:2.1.4.RELEASE‘ not found
136 0
|
Java 测试技术 Spring
Configuration problem: Failed to import bean definitions from URL location classpath:spring-mvc.xml
Configuration problem: Failed to import bean definitions from URL location classpath:spring-mvc.xml
654 0
|
Java Spring
Initialization failed for ‘https://start.spring.io‘ Please check URL, network and proxy settings解决办法
Initialization failed for ‘https://start.spring.io‘ Please check URL, network and proxy settings解决办法
2498 1
Initialization failed for ‘https://start.spring.io‘ Please check URL, network and proxy settings解决办法
|
Java Spring
spring cloud gateaway io.netty.channel.unix.Errors$NativeIoException: accept(..) failed: 打开的文件多
spring cloud gateaway io.netty.channel.unix.Errors$NativeIoException: accept(..) failed: 打开的文件多
springboot: Failed to bind properties under ‘spring.datasource’ to javax.sql.DataSource
springboot: Failed to bind properties under ‘spring.datasource’ to javax.sql.DataSource
springboot: Failed to bind properties under ‘spring.datasource’ to javax.sql.DataSource

推荐镜像

更多