Maven常规设置

  • 设置本地仓库
<localRepository>D:/software/apache-maven-3.6.1-bin/local_repository</localRepository>
  • 设置阿里云远程仓库
<mirror>
	<id>alimaven</id>
	<name>aliyun maven</name>
	<url>http://maven.aliyun.com/nexus/content/groups/public/</url>
	<mirrorOf>central</mirrorOf>
</mirror>
  • 设置默认JDK版本
<profile>    
	<id>jdk-1.8</id>    
	 <activation>    
		<activeByDefault>true</activeByDefault>    
		<jdk>1.8</jdk>    
	  </activation>    
	<properties>    
		<maven.compiler.source>1.8</maven.compiler.source>    
		<maven.compiler.target>1.8</maven.compiler.target>
		<maven.compiler.compilerVersion>1.8</maven.compiler.compilerVersion> 
	</properties>    
</profile>

参考资料

  • https://blog.csdn.net/cocplay/article/details/81782207
  • https://www.cnblogs.com/WangBoBlog/p/9150480.html
发布了24 篇原创文章 · 获赞 14 · 访问量 6万+

猜你喜欢

转载自blog.csdn.net/biubiu2it/article/details/104123423