Add main class, and refined createJar task.