配置阿里云镜像
在maven目录的setting.xml配置中进行全局配置,在mirrors节点下面添加子节点:
<mirror>
<id>nexus-aliyun</id>
<mirrorOf>central</mirrorOf>
<name>Nexus aliyun</name>
<url>http://maven.aliyun.com/nexus/content/groups/public</url>
</mirror>
其中<mirrorOf>
标签中的为本地仓库名称。
配置全局JDK版本
以JDK1.7为例,在maven目录的setting.xml配置中进行全局配置,在profiles节点下面添加子节点::
<profile>
<id>jdk-1.7</id>
<activation>
<activeByDefault>true</activeByDefault>
<jdk>1.7</jdk>
</activation>
<properties>
<maven.compiler.source>1.7</maven.compiler.source>
<maven.compiler.target>1.7</maven.compiler.target>
<maven.compiler.compilerVersion>1.7</maven.compiler.compilerVersion>
</properties>
</profile>