zoukankan      html  css  js  c++  java
  • 用Eclipse构建Maven项目

    Eclipse中m2eclipse插件的安装

    Help>Install New Software

    Click Add

    Name: m2e

    Location: http://download.eclipse.org/technology/m2e/releases

    Click OK

    It seems that the plug-in has already been installed in this version of eclipse. If not, just click next until the last and restart eclipse.

    Configuration:

      1. 绑定maven的安装目录

    Window>Preferences

    Click Add and add the installation home of maven

    Click Finish choose the item

    Click Apply and OK

      2. 设置自定义本地仓库

    Open settings.xml

    修改默认的本地仓库位置

    <localRepository>F:/m3/repository</localRepository>

    修改默认的中央仓库镜像

    <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>ibiblio</id>
          <mirrorOf>central</mirrorOf>
          <name>Human Readable Name for this Mirror.</name>
          <url>http://mirrors.ibiblio.org/maven2/</url>
        </mirror>
      </mirrors>

    保存所做的修改,同时还需要把这个settings.xml文件复制一份到“F:/m3”目录下

    Window>Preferences

    Create a new maven project

    Choose maven-archetype-webapp

    如果这一步出错了,请参考 http://jingyan.baidu.com/article/63acb44ad96e4b61fcc17ecf.html

    Group Id: 基本包名

    Artifact Id: 项目名

  • 相关阅读:
    注册表
    windows.location.href在IE6下停止工作
    LINUX配置IP的三种方式
    InnoSetup 打包代码 检测.netFramework
    SQLiteHelper
    黑马程序员_看视频记笔记_C#编程基础02
    通过注册表来检测是否安装Office
    SQLiteHelper
    TSQL
    IIS下发布关于Excel导入导出时遇到的问题集锦
  • 原文地址:https://www.cnblogs.com/wqsbk/p/4890303.html
Copyright © 2011-2022 走看看