- 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…
- Because Maven uses convention over configuration.
- Because your IDE may not support some fancy code generation/transformation you need.
- Because a build script documents the build process.
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.