简体   繁体   English

什么是常春藤?它与蚂蚁有什么关系?

[英]what is ivy? and how it is related to ant?

I have seen many ivy files in my application's build projects. 我在应用程序的构建项目中看到了很多常春藤文件。 What is Ivy, and its relation with ant? 什么是常春藤,它与蚂蚁的关系?

Ivy is an Ant extension for managing external libraries during the development process, giving you a way of adding them to your classpath, bundling them into your application build, etc. Ivy是一个Ant扩展,用于在开发过程中管理外部库,为您提供了一种将它们添加到类路径,将它们捆绑到应用程序构建中的方法等。

There's some overlap with what Maven does, but Ivy is much more lightweight (and doesn't do as much). 与Maven的作用有些重叠,但Ivy更轻巧(并且没有那么多)。

Ivy is a dependency manager -- it manages and controls the JAR files that your project depends on. Ivy是一个依赖管理器 - 它管理和控制项目所依赖的JAR文件。 If you don't have the JARs, it will pull them down for you by default (from the Maven 2 repository), which can make project setup a lot easier. 如果您没有JAR,默认情况下(默认情况下从Maven 2存储库)会为您提供 JAR,这可以使项目设置更加容易。

Ivy is originally a Jayasoft.fr product which at that time was under BSD license, however the core of Ivy has always been the same: It's a dependency management tool . Ivy最初是Jayasoft.fr产品 ,当时是BSD许可证,但Ivy的核心始终是相同的:它是一个依赖管理工具

Ivy's relation to Ant is that it is an Ant extension in the sense that it is through Ant, however it doesn't really depend on it ( beyond the obvious parts ). Ivy与Ant的关系是它是一个Ant扩展,因为它是通过Ant,但它并不真正依赖它( 超出明显的部分 )。 Ivy was merged into an Apache project under Ant as subproject through incubation process on October 11, 2007. 2007年10月11日,Ivy通过孵化过程合并到Ant下的Apache项目中作为子项目。

Very common misconception people have is that they compare Ivy with Maven as a whole. 人们常常误解的是,他们将Ivy和Maven作为一个整体进行比较。 However that doesn't really work since Ivy only handles dependencies in an agile manner and is very good at it with simplistic configuration and wide automated support with various build systems etc. through Ant while Maven really is a build system in itself. 然而,由于Ivy只能以敏捷的方式处理依赖关系并且通过简单的配置和通过Ant的各种构建系统等的广泛自动化支持非常擅长,而Maven本身就是一个构建系统。 Personal opinions may and do differ in which one does what best and that is worth several Stackoverflow/Google searches on its own. 个人意见可能并且确实有所不同,其中哪一个做得最好,并且值得自己进行多次Stackoverflow / Google搜索。

I believe these are significant and useful points to add: 我相信这些是重要且有用的要点:

  • Ivy can be used standalone from command line without Ant. Ivy可以在没有Ant的情况下从命令行独立使用。 If your CI environment does not include Ant it will not preclude you from using Ivy. 如果您的CI环境不包含Ant,则不会阻止您使用Ivy。 Yes, integration with Ant is nice and, by far, better documented. 是的,与Ant的集成很好,到目前为止,更好地记录。 One could apply Ant integration documentation to standalone usage though. 可以将Ant集成文档应用于独立使用。
  • Ivy is not just for Java. 常春藤不仅仅适用于Java。 My team successfully uses it to define dependencies for a fairly large .NET project (10 interdependent packages with several versions of each in production with multiple third party upstream dependencies). 我的团队成功地使用它来定义一个相当大的.NET项目的依赖项(10个相互依赖的包,其中每个包含多个版本,每个版本都有多个第三方上游依赖项)。 Works quite well. 效果很好。 I wish documentation were a bit clearer and fuller. 我希望文档更清晰,更全面。
  • There are additional perks that Ivy offers for Build Time: upstream and downstream builds triggering. Ivy为Build Time提供额外的额外津贴:上游和下游构建触发。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM