從nexus下載jar到本地倉庫


配置完成即可,在settings.xml的相同的標簽下進行配置

**在maven的settings.xml文件中配置下載模板**
<profile>
	<id>dev</id>
		<repositories>
		<repository>
			<id>nexus</id>
		<!--倉庫地址,即nexus倉庫組的地址-->
			<url>
			http://localhost:8081/nexus/content/groups/public/</url>
		<!--是否下載releases構件-->
			<releases>
			<enabled>true</enabled>
			</releases>
		<!--是否下載snapshots構件-->
			<snapshots>
				<enabled>true</enabled>
			</snapshots>
		</repository>
		</repositories>
<pluginRepositories>
	<!-- 插件倉庫,maven的運行依賴插件,也需要從私服下載插件 -->
	<pluginRepository>
		<id>public</id>
		<name>Public Repositories</name>
		<url>
		http://localhost:8081/nexus/content/groups/public/</url>
		</pluginRepository>
		</pluginRepositories>
</profile>


**在maven的settings.xml文件中配置激活下載模板**
<activeProfiles>
	<activeProfile>dev</activeProfile>
</activeProfiles>


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM