About The Build Tool
A ready-to-use publication build tool configuration is provided in
the default parent project supplied with the Widget Framework:
com.escenic.widget-framework:wf-project-core
. All standard
publications should use this project as their parent project - they then
inherit its publication build tool configuration, and for simple
projects no further configuration is required.
The simplest way to set up a correctly configured publication is
simply to copy and modify the demo publication supplied with the Widget
Framework in the misc/demo
folder. If you look at the
demo publication's POM file, misc/demo/pom.xml
, you
will see that it's parent project is specified as
com.escenic.widget-framework:wf-project-core
:
<parent> <groupId>com.escenic.widget-framework</groupId> <artifactId>wf-project-core</artifactId> <version>3.4.1.173597</version> <relativePath></relativePath> </parent>
If you look in the POM file of the parent
wf-project-core
project you will see a large Shade
plug-in configuration for correctly merging various publication
components into a single WAR file. This merge operation is automatically
applied to your publication - you don't need to do anything to make it
happen.
You can make use of the publication build tool in two main ways:
-
The merge process performed by the build tool mostly involves looking for particular file types in particular locations and then doing the right thing with them: moving them to the right location in the output WAR file, merging the contents into a single file and so on. If you understand what it's doing, then you can make sure that you organize the files in your project correctly so that they will be found and dealt with in the proper way. This chapter contains some guidance on how to do this in relation to specific objectives you might want to achieve, but you can also find out a lot by looking at the configuration in the
wf-project-core
POM file. -
You can also modify the standard merge process if necessary. You can do so in the following ways:
-
Add resource transformers to the default Shade plug-in configuration
-
Use
wf-build-plugin
to modify some XML files during the build -
Disable file version generation in shared projects.
These modifications can be made by adding configuration elements to your publication (or shared project) POM file and are described in Modifying the Standard Merge Process.
-