• eclipse中配置maven


    • maven安装

                  下载地址为:http://maven.apache.org/download.cgi,解压后存放在指定目录。在系统的环境变量中设置MAVEN_HOME,并在path中添加maven的bin路径。

    • eclipse中安装maven插件

                  1、在线安装,通过Help中的eclipse Maketplace进行安装。

                 2、离线安装,eclipse在线安装经常由于网速过慢无法安装,此时只能通过下载离线包进行安装。离线包直接百度下载,下载后解压,将features中内容拷贝到eclipsefeatures中,plugins文件夹中内容拷贝到eclipseplugins目录中。

    • maven配置

                  在maven的安装文件中有一个conf/settting.xml文件。设置本地中央仓库存储路径,

           <localRepository>F:
    epositorymaven</localRepository>
    

                   有时候网络较差,maven默认的中央仓库无法访问,需要设置镜像配置

      <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>
    		<id>nexus-osc</id>
    		<mirrorOf>*</mirrorOf>
    		<name>Nexus osc</name>
    		<url>http://maven.oschina.net/content/groups/public/</url>
    	</mirror>
      </mirrors>



    • 创建maven项目

                 在eclipse的菜单中选择maven project后,修改pom.xml,添加

           <packaging>jar</packaging>
           <url>http://mvnrepository.com/</url>
    • 参考资料

                 http://jingyan.baidu.com/article/db55b609a994114ba20a2f56.html
                 http://blog.csdn.net/chuyuqing/article/details/28879477

    • spring frame直接下载地址

                 http://repo.spring.io/libs-release-local/org/springframework/spring/4.1.7.RELEASE/


  • 相关阅读:
    stm32之波特率、USART
    C语言排序
    【要经常更新】C语言一些题目
    jquery瀑布流布局插件,兼容ie6不支持下拉加载,用于制作分类卡
    jquery等待图片加载完成,再使用函数,使用$(window).load(fn)
    ie6中 object doesn’t support this property or method
    jquery插件中参数未填写错误,火狐不会显示和报错,ie会显示
    flash插件使用外部数据的方法
    织梦在广告(myad)中使用css样式
    织梦改变模板目录
  • 原文地址:https://www.cnblogs.com/wala-wo/p/5119197.html
Copyright © 2020-2023  润新知