maven 仓库

ali的一个配置文件,

<?xml version="1.0" encoding="UTF-8"?>

<!--
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
-->

<!--
| This is the configuration file for Maven. It can be specified at two levels:
|
| 1. User Level. This settings.xml file provides configuration for a single user,
| and is normally provided in ${user.home}/.m2/settings.xml.
|
| NOTE: This location can be overridden with the CLI option:
|
| -s /path/to/user/settings.xml
|
| 2. Global Level. This settings.xml file provides configuration for all Maven
| users on a machine (assuming they‘re all using the same Maven
| installation). It‘s normally provided in
| ${maven.home}/conf/settings.xml.
|
| NOTE: This location can be overridden with the CLI option:
|
| -gs /path/to/global/settings.xml
|
| The sections in this sample file are intended to give you a running start at
| getting the most out of your Maven installation. Where appropriate, the default
| values (values used when the setting is not specified) are provided.
|
|-->
<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
| The path to the local repository maven will use to store artifacts.
|
| Default: ${user.home}/.m2/repository
<localRepository>/path/to/local/repo</localRepository>
-->
<localRepository>E:/repository</localRepository>

<!-- interactiveMode
| This will determine whether maven prompts you when it needs input. If set to false,
| maven will use a sensible default value, perhaps based on some other setting, for
| the parameter in question.
|
| Default: true
<interactiveMode>true</interactiveMode>
-->

<!-- offline
| Determines whether maven should attempt to connect to the network when executing a build.
| This will have an effect on artifact downloads, artifact deployment, and others.
|
| Default: false
<offline>false</offline>
-->

<!-- pluginGroups
| This is a list of additional group identifiers that will be searched when resolving plugins by their prefix, i.e.
| when invoking a command line like "mvn prefix:goal". Maven will automatically add the group identifiers
| "org.apache.maven.plugins" and "org.codehaus.mojo" if these are not already contained in the list.
|-->
<pluginGroups>
<!-- pluginGroup
| Specifies a further group identifier to use for plugin lookup.
<pluginGroup>com.your.plugins</pluginGroup>
-->
<pluginGroup>org.mortbay.jetty</pluginGroup>
</pluginGroups>

<!-- proxies
| This is a list of proxies which can be used on this machine to connect to the network.
| Unless otherwise specified (by system property or command-line switch), the first proxy
| specification in this list marked as active will be used.
|-->
<proxies>
<!-- proxy
| Specification for one proxy, to be used in connecting to the network.
|
<proxy>
<id>optional</id>
<active>true</active>
<protocol>http</protocol>
<username>proxyuser</username>
<password>proxypass</password>
<host>proxy.host.net</host>
<port>80</port>
<nonProxyHosts>local.net|some.host.com</nonProxyHosts>
</proxy>
-->
</proxies>

<!-- servers
| This is a list of authentication profiles, keyed by the server-id used within the system.
| Authentication profiles can be used whenever maven must make a connection to a remote server.
|-->
<servers>
<!-- server
| Specifies the authentication information to use when connecting to a particular server, identified by
| a unique name within the system (referred to by the ‘id‘ attribute below).
|
| NOTE: You should either specify username/password OR privateKey/passphrase, since these pairings are
| used together.
|
<server>
<id>deploymentRepo</id>
<username>repouser</username>
<password>repopwd</password>
</server>
-->

<!-- Another sample, using keys to authenticate.
<server>
<id>siteServer</id>
<privateKey>/path/to/private/key</privateKey>
<passphrase>optional; leave empty if not used.</passphrase>
</server>
-->
<server>
<id>releases</id>
<username>ali</username>
<password>ali</password>
</server>
<server>
<id>Snapshots</id>
<username>ali</username>
<password>ali</password>
</server>
</servers>

<!-- mirrors
| This is a list of mirrors to be used in downloading artifacts from remote repositories.
|
| It works like this: a POM may declare a repository to use in resolving certain artifacts.
| However, this repository may have problems with heavy traffic at times, so people have mirrored
| it to several places.
|
| That repository definition will have a unique id, so we can create a mirror reference for that
| repository, to be used as an alternate download site. The mirror site will be the preferred
| server for that repository.
|-->
<mirrors>
<!-- mirror
| Specifies a repository mirror site to use instead of a given repository. The repository that
| this mirror serves has an ID that matches the mirrorOf element of this mirror. IDs are used
| for inheritance and direct lookup purposes, and must be unique across the set of mirrors.
|
<mirror>
<id>mirrorId</id>
<mirrorOf>repositoryId</mirrorOf>
<name>Human Readable Name for this Mirror.</name>
<url>http://my.repository.com/repo/path</url>
</mirror>
-->
<mirror>
<!--This sends everything else to /public -->
<id>nexus</id>
<mirrorOf>*</mirrorOf>
<url>http://maven.aliyun.com/nexus/content/groups/public/</url>
</mirror>
<mirror>
<!--This is used to direct the public snapshots repo in the
profile below over to a different nexus group -->
<id>nexus-public-snapshots</id>
<mirrorOf>public-snapshots</mirrorOf>
<url>http://maven.aliyun.com/nexus/content/repositories/snapshots/</url>
</mirror>
<mirror>
<!--This is used to direct the public snapshots repo in the
profile below over to a different nexus group -->
<id>sonatype</id>
<mirrorOf>Sonatype Snapshots</mirrorOf>
<url>https://oss.sonatype.org/content/groups/public/</url>
</mirror>
</mirrors>

<!-- profiles
| This is a list of profiles which can be activated in a variety of ways, and which can modify
| the build process. Profiles provided in the settings.xml are intended to provide local machine-
| specific paths and repository locations which allow the build to work in the local environment.
|
| For example, if you have an integration testing plugin - like cactus - that needs to know where
| your Tomcat instance is installed, you can provide a variable here such that the variable is
| dereferenced during the build process to configure the cactus plugin.
|
| As noted above, profiles can be activated in a variety of ways. One way - the activeProfiles
| section of this document (settings.xml) - will be discussed later. Another way essentially
| relies on the detection of a system property, either matching a particular value for the property,
| or merely testing its existence. Profiles can also be activated by JDK version prefix, where a
| value of ‘1.4‘ might activate a profile when the build is executed on a JDK version of ‘1.4.2_07‘.
| Finally, the list of active profiles can be specified directly from the command line.
|
| NOTE: For profiles defined in the settings.xml, you are restricted to specifying only artifact
| repositories, plugin repositories, and free-form properties to be used as configuration
| variables for plugins in the POM.
|
|-->
<profiles>
<profile>
<id>development</id>
<repositories>
<repository>
<id>central</id>
<url>http://central</url>
<releases><enabled>true</enabled><updatePolicy>always</updatePolicy></releases>
<snapshots><enabled>true</enabled><updatePolicy>always</updatePolicy></snapshots>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>central</id>
<url>http://central</url>
<releases><enabled>true</enabled><updatePolicy>always</updatePolicy></releases>
<snapshots><enabled>true</enabled><updatePolicy>always</updatePolicy></snapshots>
</pluginRepository>
</pluginRepositories>
</profile>
<profile>
<!--this profile will allow snapshots to be searched when activated-->
<id>public-snapshots</id>
<repositories>
<repository>
<id>public-snapshots</id>
<url>http://public-snapshots</url>
<releases><enabled>false</enabled></releases>
<snapshots><enabled>true</enabled><updatePolicy>always</updatePolicy></snapshots>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>public-snapshots</id>
<url>http://public-snapshots</url>
<releases><enabled>false</enabled></releases>
<snapshots><enabled>true</enabled><updatePolicy>always</updatePolicy></snapshots>
</pluginRepository>
</pluginRepositories>
</profile>
</profiles>
<activeProfiles>
<activeProfile>development</activeProfile>
<activeProfile>public-snapshots</activeProfile>
</activeProfiles>
</settings>

  其中加入了铭飞cms的一个仓库https://oss.sonatype.org/content/groups/public/

<localRepository>E:/repository</localRepository> 设置本地路径

时间: 2024-10-13 22:27:11

maven 仓库的相关文章

maven仓库--私服(Nexus的配置使用)

1.1 私服仓库是什么 私服,私有服务器,是公司内部Maven项目经常需要的东东.Nexus是常用的私用Maven服务器,一般是公司内部使用.其作用指定私服的中央地址.将自己的Maven项目指定到私服地址.从私服下载中央库的项目索引.从私服仓库下载依赖组件.将第三方项目jar上传到私服供其他项目组使用. 1.2 Nexus中的仓库 1.2.1 类型介绍: ?  hosted,本地仓库,通常我们会部署自己的构件到这一类型的仓库.比如公司的第二方库. ?  proxy,代理仓库,它们被用来代理远程的

搭建自己的maven仓库服务器

参考 此处 常用的maven仓库 http://repo.spring.io/webapp/home.html?14 http://maven.oschina.net/home.html

maven仓库信息分析站点推荐

maven是java的一个依赖,打包管理的工具,稍微大一点的java项目都需要使用maven. 随着java的壮大,maven仓库越来越大,仓库中的jar包有60多万,各种group,各种构件,各种版本.jar包之间的依赖关系也不容易理清楚,有的jar包有很多个版本,我们很难搞清楚那个版本是更通用,各个版本之间有什么区别. 现在好了内存溢出OutOfMemory.CN开发一个maven内容分析的网站,这里有最近更新的jar包,有group的列表,还有各个版本,以及各个版本在maven中央仓库的引

maven仓库--搭建局域网私服(windows版)

使用nexus搭建局域网私服 一. 认识maven仓库 1.1 maven仓库的作用   回想之前不用maven的时候,我们用eclipse原始的项目骨架构建项目时,在工程目录下往往有一个lib文件夹用来存放工程所需jar文件,每次建一个新工程时都会有这样一个lib文件夹.然后将jar复制进lib文件夹配置路径,很显然有大量的重复工作,而且不同项目所用jar包不尽相同,需要我们慢慢去分辨.而后我们用了项目管理工具比如svn或者git,我们需要把把大量的jar文件引入代码库,这也不是一件很合适的事

阿里云yum仓库和maven仓库配置记录

阿里云yum源仓库配置: 镜像地址:http://mirrors.aliyun.com/    仓库地址:http://mirrors.aliyun.com/repo/    安装过程:        备份:mv        下载:wget        更新:yum clean all:yum makecache 阿里云maven中央仓库配置: 阿里云Maven仓库地址--加速你的maven构建    在maven的settings.xml文件里配置mirrors的子节点,添加如下mirro

maven 仓库下载缓慢,怎么解决

maven下载jar的时候会去寻国外的地址,因此造成了下载jar很缓慢,影响开发效率,于是就出现maven镜像地址,可以使我们开发人员迅速下载相关的jar. 在maven的config的setting.xml文件中,我们发现: mirror的配置就是为了镜像. 1 国内连接maven官方的仓库更新依赖库,网速一般很慢,收集一些国内快速的maven仓库镜像以备用. 2 3 ====================国内OSChina提供的镜像,非常不错=================== 4 5

Maven仓库详解

转载自:Maven入门指南④:仓库 1 . 仓库简介 没有 Maven 时,项目用到的 .jar 文件通常需要拷贝到 /lib 目录,项目多了,拷贝的文件副本就多了,占用磁盘空间,且难于管理.Maven 使用一个称之为仓库的目录,根据构件的坐标统一存储这些构件的唯一副本,在项目中通过依赖声明,可以方便的引用构件. 2 . 仓库的布局 构件都有唯一的坐标,Maven 根据坐标管理构件的存储.如以下对 spring-orm-3.2.0 的存储: 文件路径对应了:groupId/artifactId/

给 Gradle 配置国内的 Maven 仓库,提高 jar 包下载速度。

最近使用 gradle 跑一些 spring 的示例,在下载一些 jar 的时候速度特别慢,因为是访问的国外的 maven 仓库. 开源中国提供了国内的 maven 库,所以可以在 gradle 里设置一下,提供访问速度.在 build.gradle 文件中添加: buildscript { repositories { maven { url "http://maven.oschina.net" } mavenLocal() mavenCentral() } } “http://ma

使用Nexus搭建企业maven仓库(二)

先阅读<使用Nexus搭建企业maven仓库(一)> http://blog.csdn.net/ouyida3/article/details/40747545 1.官网目前最新的版本是2.10.0,从2.6开始就要求jdk7以上,否则报错: Unsupported major.minor version 51.0 (51.0是jdk1.7,,50.0是1.6,49是1,5,48是1.4) 2.如果机器不方便安装jdk1.7,下载2.5版本即可,下载地址: http://www.sonatyp

在线maven仓库

findmaven.net是一个查找Jar和查找Maven的Maven仓库搜索引擎,它可以根据Java开发者提供的Class名或者Jar名找到包含它的Jar,同时提供Jar的Maven仓库链接,Maven POM,Maven依赖树,JavaDoc,Jar源代码和Jar结构树. 如果您使用Maven作为项目构建工具,findmaven.net可以轻松的帮你解决NoClassDefFoundError和 ClassNotFoundException的异常错误. 最近findmaven.net网站加入