问题描述
我觉得这个问题的延伸Compare到IDE for Java中,我们还需要蚂蚁?
有以上问题的答案,但我想知道使用Maven或蚂蚁的一个具体例子。
当我在Eclipse开发,Eclipse中所做的一切对我来说,我只需要点击运行按钮。而且,Eclipse可以让您在code导出到一个可运行的罐子,甚至.EXE的窗口。
所以,我真的不知道为什么我需要的Maven或蚂蚁。
和也,如果我确实需要,哪一个我应该选择,Maven的蚂蚁还是?
- 因为你可能collegue preFER的NetBeans或IDEA
- 由于设置可能会从一个日食变化安装到另一个
- 因为你可能想自动获取你的依赖
- 因为要自动运行完整的构建:构建,JAR,应用静态code分析,运行单元测试,生成的文件,拷贝到某个目录,调整某些性能取决于环境,等等
- 因为一旦它的自动化,可以使用持续集成系统,它建立在每一个改变或每隔一小时申请,以确保一切仍在构建和测试仍然通过...
Eclipse是一个开发环境。但它不是一个构建工具。
我个人讨厌Maven的,但情况因人而异。有很多选择:gradle这个,buildr等
。I think this question is an extension of Compare to the IDE for Java,do we still need Ant?
There are answers for the question above, but I wish to know an concrete example of using Maven or Ant.
When I develop in Eclipse, Eclipse does everything for me and I just need to click run button. And also, Eclipse can let you export your code to an runnable jar or even .exe for windows.
So I really don't know why I need Maven or Ant.
And also if I do need, which one should I choose, Maven or Ant?
- Because your collegue might prefer NetBeans or IDEA
- Because the settings might vary from one eclipse install to another
- Because you might want to get your dependencies automatically
- Because you want to automate the complete build: build, jar, apply static code analysis, run the unit tests, generate the documentation, copy to some directory, tune some properties depending on the environment, etc.
- Because once it's automated, you can use a continuous integration system which builds the application at each change or every hour to make sure everything still builds and the tests still pass...
Eclipse is a development environment. But it's not a build tool.
I personally hate Maven, but YMMV. There are many alternatives: gradle, buildr, etc.
这篇关于为什么我们需要的Maven或Ant的,如果我们已经有Eclipse的?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!