JAVA-eclipes-maven安装配置

  1. 官网下载eclipse(http://www.eclipse.org/downloads/)
    等待下载完安装.....
  2. 配置maven 官网下载(http://maven.apache.org)
Snip20170518_3.png
Snip20170518_4.png
Snip20170518_5.png
Snip20170518_6.png
Snip20170518_9.png

配置apache-maven-3.5.0/conf/settings.xml
镜像
<mirror>
<id>alimaven</id>
<name>aliyun maven</name>
<url>http://maven.aliyun.com/nexus/content/groups/public/</url>
<mirrorOf>central</mirrorOf>
</mirror>

配置仓库地址
<localRepository>自己的目录</localRepository>

更改默认jdk为1.8 (maven默认jdk是1.5)
<profiles>
<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>

        <repositories>

            <repository>

                <id>nexus</id>

                <name>local

private nexus</name>

                <url>http://maven.oschina.net/content/groups/public/</url>

                <releases>

                    <enabled>true</enabled>

                </releases>

                <snapshots>

                    <enabled>false</enabled>

                </snapshots>

            </repository>

        </repositories>

        <pluginRepositories>

            <pluginRepository>

                <id>nexus</id>

                <name>local

private nexus</name>

                <url>http://maven.oschina.net/content/groups/public/</url>

                <releases>

                    <enabled>true</enabled>

                </releases>

                <snapshots>

                    <enabled>false</enabled>

                </snapshots>

            </pluginRepository>

        </pluginRepositories>

    </profile>

</profiles>

Snip20170518_10.png
Snip20170518_11.png
Snip20170518_12.png
Snip20170518_13.png
Snip20170518_14.png

3 新建maven项目
project explorer空白区域->new->other->maven project->next

Snip20170518_15.png
Snip20170518_16.png

最后点击finish 一个maven项目就建好了

最后编辑于
©著作权归作者所有,转载或内容合作请联系作者
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

推荐阅读更多精彩内容

  • Spring Cloud为开发人员提供了快速构建分布式系统中一些常见模式的工具(例如配置管理,服务发现,断路器,智...
    卡卡罗2017阅读 134,948评论 18 139
  • 搭建 nexus 私服(centos6.7) 备注:Centos 6.7 、 nexus-2.12.1-01-bu...
    逐暗者阅读 2,526评论 3 9
  • |-1-更新内容[6.从仓库解析依赖的机制(重要)] 1Maven仓库作用 仓库用来存储所有项目使用到构件,在ma...
    zlcook阅读 6,165评论 0 25
  • 关于maven私服 慢慢的团队人多了起来,每个新人加入时都需要从maven中心仓库下载一堆东西,而且项目拆分后互相...
    AlanKim阅读 1,154评论 5 2
  • 周末 停止了匆忙的脚步 躲进了父母的家里 卸下了一身的疲惫 早晨 鸡鸣狗吠小鸟啾啾 空气清新溪水潺潺 韭菜肥嫩蚕豆...
    若水_086阅读 345评论 1 9