If you look in the sample
subdirectory, you will see
a simple "Hello, world" application. It consists of a simple Swing
dialog that announces itself to the world. There are build files in
the sample folder for both Maven and Ant. The Ant build.xml
simply requires you to have built the jar file (see above). The
Maven project.xml
requires you to have installed
the Maven plugin, either in your local .maven folder or globally.
To build with Ant, simply run:
ant
To build with Maven, simply run:
maven mac-package
Either way, you will end up with a new application in the
sample/target
folder. This application will have a
custom icon (a globe with the word "Hello" super-imposted atop).
Double-clicking will launch the Hello World application. You will
note that the launched application has the "brushed metal" look
instead of the normal "pinstripe" look. This is accomplished by
adding the Virtual Machine option
-Dapple.awt.brushMetalLook=true
to the appropriate
place in the build file.
At this point, you are ready to start using Mac-Package in your own projects. See the installation file to see how to incorporate it in your Ant projects. You will have to specifically set it up in any Ant project that uses it. It will automatically be available to all your Maven projects once installed for the first time. Also, see the goals file to see the Maven goals provided and the properties file to see the required and optional properties.