Maven Survival Guide

 Hi Internet,
I am Giovanni `Daitan` Giorgi (you can find my fingerprint from 1993 emails out of there)
and I am a IT wizard.
I can code Java EJBs with one hand, and build a cakephp-enabled application with the other, while saying you how to set up your amazon aws in zero time.
And I can code real 6502  assembly in binary

But…I found maven difficult to master… (every hero as a Achilles’ heel..)

Maven is danger like kryptonite, you know.

So I decided to help you, poor developer,  to avoid asking me maven support at all


Step1: Download Maven 3.x or 2.x and avoid using it directly

AppFuse has done a great work providing a ready-to-use set of archetypes.

Then, the following turbo complex command will make your way to home…

mvn archetype:generate -B -DarchetypeGroupId=org.appfuse.archetypes -DarchetypeArtifactId=appfuse-light-spring-archetype -DarchetypeVersion=2.1.0 -DgroupId=it.isp.examples -DartifactId=may -DarchetypeRepository=
cd may
# Ensure no config will bother you:
mvn eclipse:clean
mvn eclipse:eclipse -DdownloadSources -DdownloadJavadocs
mvn test jetty:run-war -Dsurefire.useFile=false


Step2: Install M2Eclipse but do not use it very much

m2eclipse is not so good in my humble (but powerful) opinion. Install it but use a maven command console to compile and do the hard work.


Step3: Take a Mojto

If you are drunk, maven works better, for sure. Believe me. Take at least a beer



On 2013 I have started evaluating Gradle, which can try to pull in its world taking away maven3. Gradle sometime spots similar maven problems (like does not understanding a war must be packaged like a war and not like a jar!) but it has at least an easier to read configuration script.


Unison File Synchronizer

Several years ago I had the need of keep in sync three computers.  After some questions on a java mailing list, a very smart guy suggested me Unison.

Unison is a file-synchronization tool for Unix and Windows. It allows two replicas of a collection of files and directories to be stored on different hosts (or different disks on the same host), modified separately, and then brought up to date by propagating the changes in each replica to the other.

Unison shares a number of features with tools such as configuration management packages (CVS, PRCS, Subversion, BitKeeper, etc.), distributed filesystems (Coda, etc.), uni-directional mirroring utilities (rsync, etc.), and other synchronizers (Intellisync, Reconcile, etc). However, there are several points where it differs:[…]

read the rest on  Unison File Synchronizer.

Unison seems a bit lost in cyberspace (no new features) but the users mailing list spot some activity, so I will suggest to give it a try, because its sync alghoritm is very well written, and the MS-Window interface is good.