1. Introduction(简介)

Maven, a Yiddish word meaning accumulator of knowledge, was originally started as an attempt to simplify the build processes in the Jakarta Turbine project. There were several projects each with their own Ant build files that were all slightly different and JARs were checked into CVS. We wanted a standard way to build the projects, a clear definition of what the project consisted of, an easy way to publish project information and a way to share JARs across several projects.

Maven是一个意第绪语,意思是“知识累加器”,最初是为了简化Jakarta Turbine项目的构建过程。有几个项目每个都有自己的Ant构建文件,这些文件仅略有不同,但是jar都被导入CVS。我们想要一种标准的方法来构建项目,明确定义项目的内容,一种发布项目信息的简单方法,以及在多个项目中共享jar的方法。

The result is a tool that can now be used for building and managing any Java-based project. We hope that we have created something that will make the day-to-day work of Java developers easier and generally help with the comprehension of any Java-based project.

我们最终得到的是一个可以用于构建和管理任何基于java项目的工具。希望我们创造的东西能使Java开发人员的日常工作变得更容易,并且有助于理解任何基于Java的项目。

2. Maven’s Objectives(目标)

Maven’s primary goal is to allow a developer to comprehend the complete state of a development effort in the shortest period of time. In order to attain this goal there are several areas of concern that Maven attempts to deal with:

  • Making the build process easy
  • Providing a uniform build system
  • Providing quality project information
  • Providing guidelines for best practices development
  • Allowing transparent migration to new features

Maven的主要目标是让开发人员在最短的时间内理解开发工作的全部状态。为了实现这一目标,Maven试图解决以下几个方面的问题:

  • 使构建过程变得容易
  • 提供统一的构建系统
  • 提供高质量的项目信息
  • 为最佳实践开发提供指导方针
  • 允许透明迁移到新特性

Making the build process easy(使构建过程变得容易)

While using Maven doesn’t eliminate the need to know about the underlying mechanisms, Maven does provide a lot of shielding from the details.

虽然使用Maven并不能完全消除对底层机制的了解,但Maven确实屏蔽了大量细节。

Providing a uniform build system(提供统一的构建系统)

Maven allows a project to build using its project object model (POM) and a set of plugins that are shared by all projects using Maven, providing a uniform build system. Once you familiarize yourself with how one Maven project builds you automatically know how all Maven projects build saving you immense amounts of time when trying to navigate many projects.

Maven允许一个项目使用其项目对象模型(POM)和一组插件来构建,这些插件由使用Maven的所有项目共享,提供了一个统一的构建系统。一旦您熟悉了一个Maven项目是如何构建的,您就会自动地知道所有Maven项目是如何构建的,在您浏览许多项目时将节省大量的时间。

Providing quality project information(提供高质量的项目信息)

Maven provides plenty of useful project information that is in part taken from your POM and in part generated from your project’s sources.
For example, Maven can provide:

  • Change log document created directly from source control
  • Cross referenced sources
  • Mailing lists
  • Dependency list
  • Unit test reports including coverage

Maven提供了大量有用的项目信息,这些信息部分来自您的POM,部分来自于您的项目的源代码。
例如,Maven可以提供:

  • 从源代码控制直接创建的变更日志文档
  • 交叉引用的来源
  • 邮件列表
  • 依赖项列表
  • 包含覆盖的单元测试报告

As Maven improves the information set provided will improve, all of which will be transparent to users of Maven.

随着Maven改进所提供的信息集将得到改进,所有这些都将对Maven的用户透明。

Other products can also provide Maven plugins to allow their set of project information alongside some of the standard information given by Maven, all still based on the POM.

其他产品也提供Maven插件,让这些项目信息与Maven给出的一些标准信息一起使用,这一切都基于POM。

Providing guidelines for best practices development(为最佳实践开发提供指导方针)

Maven aims to gather current principles for best practices development, and make it easy to guide a project in that direction.
For example, specification, execution, and reporting of unit tests are part of the normal build cycle using Maven. Current unit testing best practices were used as guidelines:

  • Keeping your test source code in a separate, but parallel source tree
  • Using test case naming conventions to locate and execute tests
  • Have test cases setup their environment and don’t rely on customizing the build for test preparation.

Maven also aims to assist in project workflow such as release and issue management.

Maven also suggests some guidelines on how to layout your project’s directory structure so that once you learn the layout you can easily navigate any other project that uses Maven and the same defaults.

Maven的目标是收集当前最佳实践开发的原则,并指导项目朝着这个方向发展。
例如,单元测试的规范、执行和报告是使用Maven的正常构建周期的一部分。目前的单元测试最佳实践被用作指导方针:

  • 将你的测试源代码保存在一个单独且并行的树中
  • 使用测试用例命名约定来定位和执行测试
  • 让测试用例设置它们的环境,不要依赖于为测试准备的定制构建。

Allowing transparent migration to new features(允许透明迁移到新特性)

Maven provides an easy way for Maven clients to update their installations so that they can take advantage of any changes that been made to Maven itself.

Installation of new or updated plugins from third parties or Maven itself has been made trivial for this reason.

Maven为客户提供了一种简单的方法来更新安装,这样就可以利用对Maven本身进行的任何更改。

出于这个原因,插件来自于第三方还是来自于Maven本身安装新,已经变得不重要了。

3. What is Maven Not?(Maven是什么)

You may have heard some of the following things about Maven:

  • Maven is a site and documentation tool
  • Maven extends Ant to let you download dependencies
  • Maven is a set of reusable Ant scriptlets

对于maven,也许你听说过以下说法:

  • Maven是一个站点和文档工具
  • Maven扩展Ant,让您下载依赖项
  • Maven是一组可重用的Ant scriptlet

While Maven does these things, as you can read above in the “What is Maven?” section, these are not the only features Maven has, and its objectives are quite different.

Maven does encourage best practices, but we realise that some projects may not fit with these ideals for historical reasons. While Maven is designed to be flexible, to an extent, in these situations and to the needs of different projects, it can not cater to every situation without making compromises to the integrity of its objectives.

当Maven做这些事情的时候,您可以在上面读到"什么是Maven?",但这些并不是Maven唯一的特性,它的目标与此是完全不同的。
Maven鼓励最佳实践,但我们意识到,出于历史原因,有些项目可能与这些想法不符。虽然Maven的设计是灵活的,但在不同项目的需求中,如果不对目标的完整性做出妥协,是不能适用于每一种场景的。

If you decide to use Maven, and have an unusual build structure that you cannot reorganise, you may have to forget some features or the use of Maven altogether.

如果您决定使用Maven,并且有一个不能重新组织的构建结构,那么您可能不得不忘记一些特性或Maven的使用。

Maven介绍(翻译自官方文档)相关推荐

  1. 翻译Houdini官方文档:PDG教程之HDA处理器

    官方文档:PDG Tutorial 3 HDA Processor Part 1 关于这个教程 你将会学到什么 步骤 0 - 拷贝所需的HDA文件 步骤 1 - 观察HDA 步骤 2 - 设置PDG输 ...

  2. 翻译Houdini官方文档:PDG/TOPs介绍

    官方文档:Introduction to TOPs 总览 使用TOPs工作 TOP节点UI Processors(处理器) Mappers partitions(分割) Schedulers(调度器) ...

  3. 翻译HoudiniEngine官方文档:PDG

    官方文档:<Houdini Engine 3.6: PDG> 介绍 PDG 是一套用于对任务进行分配与管理的程序化架构. 使用 Houdini Engine,PDG的功能可以轻松地在其他应 ...

  4. 11 Themeleaf语法介绍 解读Themeleaf官方文档

    Themeleaf语法介绍 第一个入门程序 代码如下 入门程序存在的坑 [1]spring boot1.x中themeleaf中存在缓存,需要关闭 [2]themeleaf官方文档开头就讲的是国际化的 ...

  5. [翻译]ElasticSearch官方文档-安装

    本文翻译自:www.elastic.co/guide/en/el- 本文是Elasticsearch的入门文档,将会介绍ElasticSearch在不同环境下的安装. 安装 Elasticsearch ...

  6. [翻译]ElasticSearch官方文档-执行查询和过滤操作

    本文翻译自:www.elastic.co/guide/en/el- 本文是Elasticsearch的入门文档,将会介绍ElasticSearch中的查询操作和过滤操作. 执行查询 现在我们已经看到了 ...

  7. 用Lombok项目减少样板代码(翻译自官方文档)

    介绍 安装 Lombok注释 @Getter and @Setter @NonNull @ToString @EqualsAndHashCode @Data @Cleanup @Synchronize ...

  8. 翻译: Oralce官方文档-- Data Blocks, Extents, and Segments

    Data Blocks, Extents, and Segments                                                                   ...

  9. 【翻译一下官方文档】邂逅uniCloud云函数(基础篇)

    我将用图文的形式,把市面上优质的课程加以自己的理解,详细的把:创建一个uniCloud的应用,其中的每一步记录出来,方便大家写项目中,做到哪一步不会了,可以轻松翻看文章进行查阅.(此文长期更新连载) ...

最新文章

  1. Rancher 2.2.2 发布,优化 Kubernetes 集群运维
  2. 如何确定Scrum团队的最佳规模?
  3. hadoop程序开发 --- python
  4. 第四次游戏革命:全息游戏 from:http://www.cnblogs.com/alamiye010/archive/2012/08/15/2640881.html...
  5. linux桌面文件夹改图标,Linux 给桌面程序设置个性化图标
  6. android sqlite查询某个字段,Android的sqlite:如何检索特定列的特定数据?
  7. 旅行线路定制主题响应式手机模板
  8. C#开发笔记之11-如何用C#过滤连续相同的字符串?
  9. 张斌教授评《你的知识需要管理》
  10. Codeforces Round #468 (Div. 2): F. Teodor is not a liar!(DP)
  11. [webpack]手写一个mvp版本的webpack
  12. 一步一步学Repast 第二章(把界面显示出来)
  13. linux 浏览器缓存目录在哪里找,火狐浏览器缓存文件在什么位置?缓存文件位置分享...
  14. Graphics.DrawString 方法
  15. 在nameSilo购买域名
  16. ubuntu16 坚果云不能打开
  17. android接口的作用是什么意思,Android开发中接口的用处
  18. vray物理相机具体参数
  19. 游戏模型师是做什么的?薪资高不高?
  20. 计算机无法识别移动硬盘怎么办,电脑不能识别移动硬盘的原因 移动硬盘不识别怎么办...

热门文章

  1. 【计算机网络】第七章:网络安全
  2. 汽车产业链平台盛世昊通纳斯达克上市,2022完美开局
  3. libsvm java 怎么调参_libsvm使用说明
  4. 密码学-软件加密技术和注册机制
  5. java人体识别_【人体分析-人体属性识别】-Java示例代码
  6. 推荐一款快速集成 4399 原创平台的 SDK 插件
  7. 图论基础知识(一) —— 图
  8. 如何实现windows XP定时关机
  9. 分享一道一元四次方程的解法
  10. python编码规范,pycharm告警