在研究SpringBoot2.2.5启动原理的时候,下载SpringApplication.class
类文档的时候,发现报错!出现错误:
解决办法
在项目pom.xml
目录下执行
mvn dependency:resolve -Dclassifier=sources
正常来说,这么就可以解决的,但是我在运行的时候出现了一个bug
No plugin found for prefix 'dependency' in the current project and in the plugin groups [org.apache.maven.plugins, org.codehaus.mojo] available from the repositories [local (C:
\ProgramFiles\maven\apache-maven-3.6.1-bin\MavenRepository), nexus-aliyun (http://maven.aliyun.com/nexus/content/groups/public)] -> [Help 1]
通过https://stackoverflow.com/questions/48939973/maven-no-plugin-found-for-prefix-dependency-in-the-current-project-and-in-the 提示,解决问题,
在pom.xml
文件中添加:
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<version>3.0.2</version>
<executions>
<execution>
<id>copy-dependencies</id>
<phase>package</phase>
<goals>
<goal>copy-dependencies</goal>
</goals>
<configuration>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)