dmy

About Flaka

written by admin 584 days ago. Last update at 2010-02-24 13:25:03. Categories Uncategorized.

In the world of Java, build scripts are traditionally written in Ant and nowadays Maven.

When it comes to write a build script using Ant, it feels like using a Shell script in a rather awkward language (XML). Each Ant task solves a particular problem. This is similar to a Shell where you have this small masterpieces like mkdir, cp, tar plus some control structures to eventually being able to put the one big thing together.

Writing a build script using a Shell is serious. And so it is using Ant. Ant does not provide you any abstraction how the project needs to be build. There is no underlying logic. In fact you, the author, need to know what to do. Step by step. Therefore, Ant scripts are large, notoriously difficult to understand, usually not portable (usuallyt they just work on the authors host) and each author uses a different set of targets and properties.

Maven on the other side provides a high abstraction of building a project. Instead of describing how the project needs to be build, just describe project details and reports you like to have and Maven figures out what needs to be done. This is probably the reason why Maven gains so much popularity.

Despite better knowledge I wrote that Maven figures out how a project needs to be build automatically. That’s actually not quite true. In fact, Maven only works fine when following conventions setup by the Maven team. When not “en route”, Maven gets difficult as well. For example, try to create a release package with Maven. At the end you find yourself using Ant again.

Flaka is a framework build on to of Ant. It’s main goal is to simplify the process of writing a build script. It comes with a high abstraction a la Maven while providing the natural power of Ant to escape from defaults.